.class public Lcom/htc/android/footprints/utils/FootprintUtils;
.super Ljava/lang/Object;
.source "FootprintUtils.java"


# static fields
.field public static CORRECT_FOOTPRINT:I = 0x0

.field public static ERR_FOOTPRINT_ADDRESS:I = 0x0

.field public static ERR_FOOTPRINT_NAME:I = 0x0

.field public static ERR_FOOTPRINT_PHONE:I = 0x0

.field public static ERR_FOOTPRINT_WEB:I = 0x0

.field private static final LAT_LON_PATTERN:Ljava/lang/String; = "{0}\u00b0 {1}\'\' {2}\" {3}"

.field private static final SEC_PATTERN:Ljava/lang/String; = "###.##"

.field protected static final TAG:Ljava/lang/String; = "FootprintUtils"


# direct methods
.method static constructor <clinit>()V
    .locals 1

    .prologue
    .line 971
    const/4 v0, 0x0

    sput v0, Lcom/htc/android/footprints/utils/FootprintUtils;->CORRECT_FOOTPRINT:I

    .line 972
    const/4 v0, -0x1

    sput v0, Lcom/htc/android/footprints/utils/FootprintUtils;->ERR_FOOTPRINT_NAME:I

    .line 973
    const/4 v0, -0x2

    sput v0, Lcom/htc/android/footprints/utils/FootprintUtils;->ERR_FOOTPRINT_PHONE:I

    .line 974
    const/4 v0, -0x3

    sput v0, Lcom/htc/android/footprints/utils/FootprintUtils;->ERR_FOOTPRINT_WEB:I

    .line 975
    const/4 v0, -0x4

    sput v0, Lcom/htc/android/footprints/utils/FootprintUtils;->ERR_FOOTPRINT_ADDRESS:I

    return-void
.end method

.method public constructor <init>()V
    .locals 0

    .prologue
    .line 60
    invoke-direct {p0}, Ljava/lang/Object;-><init>()V

    return-void
.end method

.method public static CopyToNewExif(Ljava/io/File;Ljava/io/File;)Z
    .locals 9
    .parameter "old_file"
    .parameter "new_file"

    .prologue
    const/4 v8, 0x0

    .line 336
    invoke-virtual {p0}, Ljava/io/File;->exists()Z

    move-result v7

    if-nez v7, :cond_0

    move v7, v8

    .line 360
    :goto_0
    return v7

    .line 338
    :cond_0
    invoke-virtual {p1}, Ljava/io/File;->exists()Z

    move-result v7

    if-nez v7, :cond_1

    move v7, v8

    .line 339
    goto :goto_0

    .line 341
    :cond_1
    const/4 v3, 0x0

    .line 342
    .local v3, mOldExifData:Ljava/util/HashMap;,"Ljava/util/HashMap<Ljava/lang/String;Ljava/lang/String;>;"
    new-instance v5, Lcom/htc/android/footprints/utils/ExifInterface;

    invoke-virtual {p1}, Ljava/io/File;->getAbsolutePath()Ljava/lang/String;

    move-result-object v7

    invoke-direct {v5, v7}, Lcom/htc/android/footprints/utils/ExifInterface;-><init>(Ljava/lang/String;)V

    .line 343
    .local v5, old_exif:Lcom/htc/android/footprints/utils/ExifInterface;
    invoke-virtual {v5}, Lcom/htc/android/footprints/utils/ExifInterface;->getAttributes()Ljava/util/HashMap;

    move-result-object v3

    .line 345
    const/4 v2, 0x0

    .line 346
    .local v2, mNewExifData:Ljava/util/HashMap;,"Ljava/util/HashMap<Ljava/lang/String;Ljava/lang/String;>;"
    new-instance v4, Lcom/htc/android/footprints/utils/ExifInterface;

    invoke-virtual {p0}, Ljava/io/File;->getAbsolutePath()Ljava/lang/String;

    move-result-object v7

    invoke-direct {v4, v7}, Lcom/htc/android/footprints/utils/ExifInterface;-><init>(Ljava/lang/String;)V

    .line 347
    .local v4, new_exif:Lcom/htc/android/footprints/utils/ExifInterface;
    invoke-virtual {v4}, Lcom/htc/android/footprints/utils/ExifInterface;->getAttributes()Ljava/util/HashMap;

    move-result-object v2

    .line 349
    invoke-virtual {v3}, Ljava/util/HashMap;->keySet()Ljava/util/Set;

    move-result-object v7

    invoke-interface {v7}, Ljava/util/Set;->iterator()Ljava/util/Iterator;

    move-result-object v1

    .line 350
    .local v1, keyIterator:Ljava/util/Iterator;
    :goto_1
    invoke-interface {v1}, Ljava/util/Iterator;->hasNext()Z

    move-result v7

    if-eqz v7, :cond_2

    .line 351
    invoke-interface {v1}, Ljava/util/Iterator;->next()Ljava/lang/Object;

    move-result-object v0

    check-cast v0, Ljava/lang/String;

    .line 352
    .local v0, key:Ljava/lang/String;
    invoke-virtual {v3, v0}, Ljava/util/HashMap;->get(Ljava/lang/Object;)Ljava/lang/Object;

    move-result-object v6

    check-cast v6, Ljava/lang/String;

    .line 354
    .local v6, val:Ljava/lang/String;
    invoke-static {v2, v0, v6}, Lcom/htc/android/footprints/utils/FootprintUtils;->replaceExifTag(Ljava/util/HashMap;Ljava/lang/String;Ljava/lang/String;)V

    goto :goto_1

    .line 357
    .end local v0           #key:Ljava/lang/String;
    .end local v6           #val:Ljava/lang/String;
    :cond_2
    invoke-virtual {v4, v2}, Lcom/htc/android/footprints/utils/ExifInterface;->saveAttributes(Ljava/util/HashMap;)V

    .line 358
    invoke-virtual {v4}, Lcom/htc/android/footprints/utils/ExifInterface;->commitChanges()V

    .line 360
    const/4 v7, 0x1

    goto :goto_0
.end method

.method public static boundCenterBottom(Landroid/graphics/drawable/Drawable;)Landroid/graphics/drawable/Drawable;
    .locals 7
    .parameter "balloon"

    .prologue
    const/4 v6, 0x1

    .line 1223
    invoke-virtual {p0}, Landroid/graphics/drawable/Drawable;->getIntrinsicWidth()I

    move-result v2

    .line 1224
    .local v2, width:I
    div-int/lit8 v1, v2, 0x2

    .line 1225
    .local v1, w2:I
    invoke-virtual {p0}, Landroid/graphics/drawable/Drawable;->getIntrinsicHeight()I

    move-result v0

    .line 1226
    .local v0, height:I
    neg-int v3, v1

    sub-int v4, v6, v0

    sub-int v5, v2, v1

    invoke-virtual {p0, v3, v4, v5, v6}, Landroid/graphics/drawable/Drawable;->setBounds(IIII)V

    .line 1227
    return-object p0
.end method

.method public static checkAudioData(Lcom/htc/android/footprints/vo/Footprint;)Z
    .locals 3
    .parameter "data"

    .prologue
    const/4 v2, 0x0

    .line 231
    if-nez p0, :cond_0

    move v0, v2

    .line 239
    :goto_0
    return v0

    .line 233
    :cond_0
    iget-object v0, p0, Lcom/htc/android/footprints/vo/Footprint;->mAudioPath:Ljava/lang/String;

    if-nez v0, :cond_1

    move v0, v2

    .line 234
    goto :goto_0

    .line 235
    :cond_1
    iget-object v0, p0, Lcom/htc/android/footprints/vo/Footprint;->mAudioPath:Ljava/lang/String;

    const-string v1, ""

    invoke-virtual {v0, v1}, Ljava/lang/String;->equalsIgnoreCase(Ljava/lang/String;)Z

    move-result v0

    if-eqz v0, :cond_2

    move v0, v2

    .line 236
    goto :goto_0

    .line 237
    :cond_2
    new-instance v0, Ljava/io/File;

    iget-object v1, p0, Lcom/htc/android/footprints/vo/Footprint;->mAudioPath:Ljava/lang/String;

    invoke-direct {v0, v1}, Ljava/io/File;-><init>(Ljava/lang/String;)V

    invoke-virtual {v0}, Ljava/io/File;->exists()Z

    move-result v0

    if-nez v0, :cond_3

    move v0, v2

    .line 238
    goto :goto_0

    .line 239
    :cond_3
    const/4 v0, 0x1

    goto :goto_0
.end method

.method public static checkAudioData(Ljava/lang/String;)Z
    .locals 2
    .parameter "filepath"

    .prologue
    const/4 v1, 0x0

    .line 243
    if-nez p0, :cond_0

    move v0, v1

    .line 249
    :goto_0
    return v0

    .line 245
    :cond_0
    const-string v0, ""

    invoke-virtual {p0, v0}, Ljava/lang/String;->equalsIgnoreCase(Ljava/lang/String;)Z

    move-result v0

    if-eqz v0, :cond_1

    move v0, v1

    .line 246
    goto :goto_0

    .line 247
    :cond_1
    new-instance v0, Ljava/io/File;

    invoke-direct {v0, p0}, Ljava/io/File;-><init>(Ljava/lang/String;)V

    invoke-virtual {v0}, Ljava/io/File;->exists()Z

    move-result v0

    if-nez v0, :cond_2

    move v0, v1

    .line 248
    goto :goto_0

    .line 249
    :cond_2
    const/4 v0, 0x1

    goto :goto_0
.end method

.method public static checkFootprintLimitation(Lcom/htc/android/footprints/vo/Footprint;)I
    .locals 4
    .parameter "f"

    .prologue
    const/16 v3, 0x1ff

    .line 978
    sget v0, Lcom/htc/android/footprints/utils/FootprintUtils;->CORRECT_FOOTPRINT:I

    .line 979
    .local v0, isCorrect:I
    iget-object v1, p0, Lcom/htc/android/footprints/vo/Footprint;->mName:Ljava/lang/String;

    if-eqz v1, :cond_0

    iget-object v1, p0, Lcom/htc/android/footprints/vo/Footprint;->mName:Ljava/lang/String;

    invoke-virtual {v1}, Ljava/lang/String;->length()I

    move-result v1

    const/16 v2, 0x30

    if-le v1, v2, :cond_1

    .line 981
    :cond_0
    sget v1, Lcom/htc/android/footprints/utils/FootprintUtils;->ERR_FOOTPRINT_NAME:I

    .line 992
    :goto_0
    return v1

    .line 982
    :cond_1
    iget-object v1, p0, Lcom/htc/android/footprints/vo/Footprint;->mTel:Ljava/lang/String;

    if-eqz v1, :cond_2

    iget-object v1, p0, Lcom/htc/android/footprints/vo/Footprint;->mTel:Ljava/lang/String;

    invoke-virtual {v1}, Ljava/lang/String;->length()I

    move-result v1

    const/16 v2, 0x14

    if-le v1, v2, :cond_3

    .line 984
    :cond_2
    sget v1, Lcom/htc/android/footprints/utils/FootprintUtils;->ERR_FOOTPRINT_PHONE:I

    goto :goto_0

    .line 985
    :cond_3
    iget-object v1, p0, Lcom/htc/android/footprints/vo/Footprint;->mSite:Ljava/lang/String;

    if-eqz v1, :cond_4

    iget-object v1, p0, Lcom/htc/android/footprints/vo/Footprint;->mSite:Ljava/lang/String;

    invoke-virtual {v1}, Ljava/lang/String;->length()I

    move-result v1

    if-le v1, v3, :cond_5

    .line 987
    :cond_4
    sget v1, Lcom/htc/android/footprints/utils/FootprintUtils;->ERR_FOOTPRINT_WEB:I

    goto :goto_0

    .line 988
    :cond_5
    iget-object v1, p0, Lcom/htc/android/footprints/vo/Footprint;->mAddr:Ljava/lang/String;

    if-eqz v1, :cond_6

    iget-object v1, p0, Lcom/htc/android/footprints/vo/Footprint;->mAddr:Ljava/lang/String;

    invoke-virtual {v1}, Ljava/lang/String;->length()I

    move-result v1

    if-le v1, v3, :cond_7

    .line 990
    :cond_6
    sget v1, Lcom/htc/android/footprints/utils/FootprintUtils;->ERR_FOOTPRINT_ADDRESS:I

    goto :goto_0

    :cond_7
    move v1, v0

    .line 992
    goto :goto_0
.end method

.method public static checkPhotoData(Ljava/lang/String;)Z
    .locals 2
    .parameter "filepath"

    .prologue
    const/4 v1, 0x0

    .line 253
    if-nez p0, :cond_0

    move v0, v1

    .line 259
    :goto_0
    return v0

    .line 255
    :cond_0
    const-string v0, ""

    invoke-virtual {p0, v0}, Ljava/lang/String;->equalsIgnoreCase(Ljava/lang/String;)Z

    move-result v0

    if-eqz v0, :cond_1

    move v0, v1

    .line 256
    goto :goto_0

    .line 257
    :cond_1
    new-instance v0, Ljava/io/File;

    invoke-direct {v0, p0}, Ljava/io/File;-><init>(Ljava/lang/String;)V

    invoke-virtual {v0}, Ljava/io/File;->exists()Z

    move-result v0

    if-nez v0, :cond_2

    move v0, v1

    .line 258
    goto :goto_0

    .line 259
    :cond_2
    const/4 v0, 0x1

    goto :goto_0
.end method

.method public static convertRationalLatLonToDecimalString(Ljava/lang/String;)F
    .locals 10
    .parameter "rationalString"

    .prologue
    const-string v7, "/"

    .line 384
    :try_start_0
    const-string v7, ","

    invoke-virtual {p0, v7}, Ljava/lang/String;->split(Ljava/lang/String;)[Ljava/lang/String;

    move-result-object v4

    .line 387
    .local v4, parts:[Ljava/lang/String;
    const/4 v7, 0x0

    aget-object v7, v4, v7

    const-string v8, "/"

    invoke-virtual {v7, v8}, Ljava/lang/String;->split(Ljava/lang/String;)[Ljava/lang/String;

    move-result-object v3

    .line 388
    .local v3, pair:[Ljava/lang/String;
    const/4 v7, 0x0

    aget-object v7, v3, v7

    invoke-virtual {v7}, Ljava/lang/String;->trim()Ljava/lang/String;

    move-result-object v7

    invoke-static {v7}, Ljava/lang/Float;->parseFloat(Ljava/lang/String;)F

    move-result v7

    const/4 v8, 0x1

    aget-object v8, v3, v8

    invoke-virtual {v8}, Ljava/lang/String;->trim()Ljava/lang/String;

    move-result-object v8

    invoke-static {v8}, Ljava/lang/Float;->parseFloat(Ljava/lang/String;)F

    move-result v8

    div-float/2addr v7, v8

    float-to-int v0, v7

    .line 391
    .local v0, degrees:I
    const/4 v7, 0x1

    aget-object v7, v4, v7

    const-string v8, "/"

    invoke-virtual {v7, v8}, Ljava/lang/String;->split(Ljava/lang/String;)[Ljava/lang/String;

    move-result-object v3

    .line 392
    const/4 v7, 0x0

    aget-object v7, v3, v7

    invoke-virtual {v7}, Ljava/lang/String;->trim()Ljava/lang/String;

    move-result-object v7

    invoke-static {v7}, Ljava/lang/Float;->parseFloat(Ljava/lang/String;)F

    move-result v7

    const/4 v8, 0x1

    aget-object v8, v3, v8

    invoke-virtual {v8}, Ljava/lang/String;->trim()Ljava/lang/String;

    move-result-object v8

    invoke-static {v8}, Ljava/lang/Float;->parseFloat(Ljava/lang/String;)F

    move-result v8

    div-float/2addr v7, v8

    float-to-int v2, v7

    .line 395
    .local v2, minutes:I
    const/4 v7, 0x2

    aget-object v7, v4, v7

    const-string v8, "/"

    invoke-virtual {v7, v8}, Ljava/lang/String;->split(Ljava/lang/String;)[Ljava/lang/String;

    move-result-object v3

    .line 396
    const/4 v7, 0x0

    aget-object v7, v3, v7

    invoke-virtual {v7}, Ljava/lang/String;->trim()Ljava/lang/String;

    move-result-object v7

    invoke-static {v7}, Ljava/lang/Float;->parseFloat(Ljava/lang/String;)F

    move-result v7

    const/4 v8, 0x1

    aget-object v8, v3, v8

    invoke-virtual {v8}, Ljava/lang/String;->trim()Ljava/lang/String;

    move-result-object v8

    invoke-static {v8}, Ljava/lang/Float;->parseFloat(Ljava/lang/String;)F
    :try_end_0
    .catch Ljava/lang/Exception; {:try_start_0 .. :try_end_0} :catch_0

    move-result v8

    div-float v6, v7, v8

    .line 399
    .local v6, seconds:F
    int-to-float v7, v0

    int-to-float v8, v2

    const/high16 v9, 0x4270

    div-float/2addr v8, v9

    add-float/2addr v7, v8

    const/high16 v8, 0x4561

    div-float v8, v6, v8

    add-float v5, v7, v8

    .local v5, result:F
    move v7, v5

    .line 405
    .end local v0           #degrees:I
    .end local v2           #minutes:I
    .end local v3           #pair:[Ljava/lang/String;
    .end local v4           #parts:[Ljava/lang/String;
    .end local v5           #result:F
    .end local v6           #seconds:F
    :goto_0
    return v7

    .line 402
    :catch_0
    move-exception v7

    move-object v1, v7

    .line 405
    .local v1, ex:Ljava/lang/Exception;
    const/4 v7, 0x0

    goto :goto_0
.end method

.method public static convertRationalLatLonToInt(Ljava/lang/String;)I
    .locals 11
    .parameter "rationalString"

    .prologue
    const/4 v9, 0x0

    const-string v7, "/"

    .line 412
    :try_start_0
    const-string v7, ","

    invoke-virtual {p0, v7}, Ljava/lang/String;->split(Ljava/lang/String;)[Ljava/lang/String;

    move-result-object v4

    .line 415
    .local v4, parts:[Ljava/lang/String;
    const/4 v7, 0x0

    aget-object v7, v4, v7

    const-string v8, "/"

    invoke-virtual {v7, v8}, Ljava/lang/String;->split(Ljava/lang/String;)[Ljava/lang/String;

    move-result-object v3

    .line 416
    .local v3, pair:[Ljava/lang/String;
    const/4 v7, 0x0

    aget-object v7, v3, v7

    invoke-virtual {v7}, Ljava/lang/String;->trim()Ljava/lang/String;

    move-result-object v7

    invoke-static {v7}, Ljava/lang/Float;->parseFloat(Ljava/lang/String;)F

    move-result v7

    const/4 v8, 0x1

    aget-object v8, v3, v8

    invoke-virtual {v8}, Ljava/lang/String;->trim()Ljava/lang/String;

    move-result-object v8

    invoke-static {v8}, Ljava/lang/Float;->parseFloat(Ljava/lang/String;)F

    move-result v8

    div-float/2addr v7, v8

    float-to-int v0, v7

    .line 419
    .local v0, degrees:I
    const/4 v7, 0x1

    aget-object v7, v4, v7

    const-string v8, "/"

    invoke-virtual {v7, v8}, Ljava/lang/String;->split(Ljava/lang/String;)[Ljava/lang/String;

    move-result-object v3

    .line 420
    const/4 v7, 0x0

    aget-object v7, v3, v7

    invoke-virtual {v7}, Ljava/lang/String;->trim()Ljava/lang/String;

    move-result-object v7

    invoke-static {v7}, Ljava/lang/Float;->parseFloat(Ljava/lang/String;)F

    move-result v7

    const/4 v8, 0x1

    aget-object v8, v3, v8

    invoke-virtual {v8}, Ljava/lang/String;->trim()Ljava/lang/String;

    move-result-object v8

    invoke-static {v8}, Ljava/lang/Float;->parseFloat(Ljava/lang/String;)F

    move-result v8

    div-float/2addr v7, v8

    float-to-int v2, v7

    .line 423
    .local v2, minutes:I
    const/4 v7, 0x2

    aget-object v7, v4, v7

    const-string v8, "/"

    invoke-virtual {v7, v8}, Ljava/lang/String;->split(Ljava/lang/String;)[Ljava/lang/String;

    move-result-object v3

    .line 424
    const/4 v7, 0x0

    aget-object v7, v3, v7

    invoke-virtual {v7}, Ljava/lang/String;->trim()Ljava/lang/String;

    move-result-object v7

    invoke-static {v7}, Ljava/lang/Float;->parseFloat(Ljava/lang/String;)F

    move-result v7

    const/4 v8, 0x1

    aget-object v8, v3, v8

    invoke-virtual {v8}, Ljava/lang/String;->trim()Ljava/lang/String;

    move-result-object v8

    invoke-static {v8}, Ljava/lang/Float;->parseFloat(Ljava/lang/String;)F
    :try_end_0
    .catch Ljava/lang/Exception; {:try_start_0 .. :try_end_0} :catch_0

    move-result v8

    div-float v6, v7, v8

    .line 427
    .local v6, seconds:F
    int-to-float v7, v0

    int-to-float v8, v2

    const/high16 v9, 0x4270

    div-float/2addr v8, v9

    add-float/2addr v7, v8

    const/high16 v8, 0x4561

    div-float v8, v6, v8

    add-float/2addr v7, v8

    float-to-double v7, v7

    const-wide v9, 0x412e848000000000L

    mul-double/2addr v7, v9

    double-to-int v5, v7

    .local v5, result:I
    move v7, v5

    .line 434
    .end local v0           #degrees:I
    .end local v2           #minutes:I
    .end local v3           #pair:[Ljava/lang/String;
    .end local v4           #parts:[Ljava/lang/String;
    .end local v5           #result:I
    .end local v6           #seconds:F
    :goto_0
    return v7

    .line 431
    :catch_0
    move-exception v7

    move-object v1, v7

    .local v1, ex:Ljava/lang/Exception;
    move v7, v9

    .line 434
    goto :goto_0
.end method

.method public static convertRationalLatLonToInt(Ljava/lang/String;Ljava/lang/String;)I
    .locals 3
    .parameter "rationalString"
    .parameter "orientation"

    .prologue
    .line 439
    const/4 v0, 0x0

    .line 440
    .local v0, location:I
    if-eqz p0, :cond_0

    invoke-virtual {p0}, Ljava/lang/String;->trim()Ljava/lang/String;

    move-result-object v1

    const-string v2, "null"

    invoke-virtual {v1, v2}, Ljava/lang/String;->equalsIgnoreCase(Ljava/lang/String;)Z

    move-result v1

    if-nez v1, :cond_0

    invoke-virtual {p0}, Ljava/lang/String;->length()I

    move-result v1

    const/4 v2, 0x5

    if-ge v1, v2, :cond_3

    .line 441
    :cond_0
    const/4 v0, 0x0

    .line 445
    :goto_0
    if-eqz p1, :cond_2

    invoke-virtual {p1}, Ljava/lang/String;->trim()Ljava/lang/String;

    move-result-object v1

    invoke-virtual {v1}, Ljava/lang/String;->length()I

    move-result v1

    const/4 v2, 0x1

    if-ne v1, v2, :cond_2

    .line 446
    invoke-virtual {p1}, Ljava/lang/String;->trim()Ljava/lang/String;

    move-result-object v1

    const-string v2, "W"

    invoke-virtual {v1, v2}, Ljava/lang/String;->equalsIgnoreCase(Ljava/lang/String;)Z

    move-result v1

    if-nez v1, :cond_1

    invoke-virtual {p1}, Ljava/lang/String;->trim()Ljava/lang/String;

    move-result-object v1

    const-string v2, "S"

    invoke-virtual {v1, v2}, Ljava/lang/String;->equalsIgnoreCase(Ljava/lang/String;)Z

    move-result v1

    if-nez v1, :cond_1

    if-eqz v0, :cond_2

    .line 447
    :cond_1
    mul-int/lit8 v0, v0, -0x1

    .line 451
    :cond_2
    return v0

    .line 443
    :cond_3
    invoke-static {p0}, Lcom/htc/android/footprints/utils/FootprintUtils;->convertRationalLatLonToInt(Ljava/lang/String;)I

    move-result v0

    goto :goto_0
.end method

.method public static copyFile(Ljava/io/File;Ljava/io/File;)Z
    .locals 9
    .parameter "source"
    .parameter "target"

    .prologue
    const-string v8, "FootprintUtils"

    .line 710
    if-eqz p0, :cond_0

    invoke-virtual {p0}, Ljava/io/File;->exists()Z

    move-result v2

    if-eqz v2, :cond_0

    if-nez p1, :cond_1

    .line 711
    :cond_0
    const/4 v2, 0x0

    .line 746
    :goto_0
    return v2

    .line 716
    :cond_1
    const/4 v1, 0x0

    .line 717
    .local v1, in:Ljava/nio/channels/FileChannel;
    const/4 v0, 0x0

    .line 720
    .local v0, out:Ljava/nio/channels/FileChannel;
    :try_start_0
    new-instance v2, Ljava/io/FileInputStream;

    invoke-direct {v2, p0}, Ljava/io/FileInputStream;-><init>(Ljava/io/File;)V

    invoke-virtual {v2}, Ljava/io/FileInputStream;->getChannel()Ljava/nio/channels/FileChannel;

    move-result-object v1

    .line 721
    new-instance v7, Ljava/io/FileOutputStream;

    invoke-direct {v7, p1}, Ljava/io/FileOutputStream;-><init>(Ljava/io/File;)V

    .line 722
    .local v7, outf:Ljava/io/FileOutputStream;
    invoke-virtual {v7}, Ljava/io/FileOutputStream;->getChannel()Ljava/nio/channels/FileChannel;

    move-result-object v0

    .line 723
    const-wide/16 v2, 0x0

    invoke-virtual {v1}, Ljava/nio/channels/FileChannel;->size()J

    move-result-wide v4

    invoke-virtual/range {v0 .. v5}, Ljava/nio/channels/FileChannel;->transferFrom(Ljava/nio/channels/ReadableByteChannel;JJ)J

    .line 724
    invoke-virtual {v7}, Ljava/io/FileOutputStream;->getFD()Ljava/io/FileDescriptor;

    move-result-object v2

    invoke-virtual {v2}, Ljava/io/FileDescriptor;->sync()V
    :try_end_0
    .catchall {:try_start_0 .. :try_end_0} :catchall_0
    .catch Ljava/lang/Exception; {:try_start_0 .. :try_end_0} :catch_2

    .line 728
    if-eqz v1, :cond_2

    .line 730
    :try_start_1
    invoke-virtual {v1}, Ljava/nio/channels/FileChannel;->close()V
    :try_end_1
    .catch Ljava/io/IOException; {:try_start_1 .. :try_end_1} :catch_0

    .line 734
    :goto_1
    const/4 v1, 0x0

    .line 736
    :cond_2
    if-eqz v0, :cond_3

    .line 738
    :try_start_2
    invoke-virtual {v0}, Ljava/nio/channels/FileChannel;->close()V
    :try_end_2
    .catch Ljava/io/IOException; {:try_start_2 .. :try_end_2} :catch_1

    .line 742
    :goto_2
    const/4 v0, 0x0

    .line 746
    .end local v7           #outf:Ljava/io/FileOutputStream;
    :cond_3
    :goto_3
    const/4 v2, 0x1

    goto :goto_0

    .line 731
    .restart local v7       #outf:Ljava/io/FileOutputStream;
    :catch_0
    move-exception v6

    .line 732
    .local v6, e:Ljava/io/IOException;
    const-string v2, "FootprintUtils"

    invoke-virtual {v6}, Ljava/io/IOException;->getMessage()Ljava/lang/String;

    move-result-object v2

    invoke-static {v8, v2, v6}, Landroid/util/Log;->w(Ljava/lang/String;Ljava/lang/String;Ljava/lang/Throwable;)I

    goto :goto_1

    .line 739
    .end local v6           #e:Ljava/io/IOException;
    :catch_1
    move-exception v6

    .line 740
    .restart local v6       #e:Ljava/io/IOException;
    const-string v2, "FootprintUtils"

    invoke-virtual {v6}, Ljava/io/IOException;->getMessage()Ljava/lang/String;

    move-result-object v2

    invoke-static {v8, v2, v6}, Landroid/util/Log;->w(Ljava/lang/String;Ljava/lang/String;Ljava/lang/Throwable;)I

    goto :goto_2

    .line 725
    .end local v6           #e:Ljava/io/IOException;
    .end local v7           #outf:Ljava/io/FileOutputStream;
    :catch_2
    move-exception v2

    move-object v6, v2

    .line 726
    .local v6, e:Ljava/lang/Exception;
    :try_start_3
    const-string v2, "FootprintUtils"

    invoke-virtual {v6}, Ljava/lang/Exception;->getMessage()Ljava/lang/String;

    move-result-object v3

    invoke-static {v2, v3, v6}, Landroid/util/Log;->e(Ljava/lang/String;Ljava/lang/String;Ljava/lang/Throwable;)I
    :try_end_3
    .catchall {:try_start_3 .. :try_end_3} :catchall_0

    .line 728
    if-eqz v1, :cond_4

    .line 730
    :try_start_4
    invoke-virtual {v1}, Ljava/nio/channels/FileChannel;->close()V
    :try_end_4
    .catch Ljava/io/IOException; {:try_start_4 .. :try_end_4} :catch_3

    .line 734
    .end local v6           #e:Ljava/lang/Exception;
    :goto_4
    const/4 v1, 0x0

    .line 736
    :cond_4
    if-eqz v0, :cond_3

    .line 738
    :try_start_5
    invoke-virtual {v0}, Ljava/nio/channels/FileChannel;->close()V
    :try_end_5
    .catch Ljava/io/IOException; {:try_start_5 .. :try_end_5} :catch_4

    .line 742
    :goto_5
    const/4 v0, 0x0

    goto :goto_3

    .line 731
    .restart local v6       #e:Ljava/lang/Exception;
    :catch_3
    move-exception v6

    .line 732
    .local v6, e:Ljava/io/IOException;
    const-string v2, "FootprintUtils"

    invoke-virtual {v6}, Ljava/io/IOException;->getMessage()Ljava/lang/String;

    move-result-object v2

    invoke-static {v8, v2, v6}, Landroid/util/Log;->w(Ljava/lang/String;Ljava/lang/String;Ljava/lang/Throwable;)I

    goto :goto_4

    .line 739
    .end local v6           #e:Ljava/io/IOException;
    :catch_4
    move-exception v6

    .line 740
    .restart local v6       #e:Ljava/io/IOException;
    const-string v2, "FootprintUtils"

    invoke-virtual {v6}, Ljava/io/IOException;->getMessage()Ljava/lang/String;

    move-result-object v2

    invoke-static {v8, v2, v6}, Landroid/util/Log;->w(Ljava/lang/String;Ljava/lang/String;Ljava/lang/Throwable;)I

    goto :goto_5

    .line 728
    .end local v6           #e:Ljava/io/IOException;
    :catchall_0
    move-exception v2

    if-eqz v1, :cond_5

    .line 730
    :try_start_6
    invoke-virtual {v1}, Ljava/nio/channels/FileChannel;->close()V
    :try_end_6
    .catch Ljava/io/IOException; {:try_start_6 .. :try_end_6} :catch_5

    .line 734
    :goto_6
    const/4 v1, 0x0

    .line 736
    :cond_5
    if-eqz v0, :cond_6

    .line 738
    :try_start_7
    invoke-virtual {v0}, Ljava/nio/channels/FileChannel;->close()V
    :try_end_7
    .catch Ljava/io/IOException; {:try_start_7 .. :try_end_7} :catch_6

    .line 742
    :goto_7
    const/4 v0, 0x0

    :cond_6
    throw v2

    .line 731
    :catch_5
    move-exception v6

    .line 732
    .restart local v6       #e:Ljava/io/IOException;
    const-string v3, "FootprintUtils"

    invoke-virtual {v6}, Ljava/io/IOException;->getMessage()Ljava/lang/String;

    move-result-object v3

    invoke-static {v8, v3, v6}, Landroid/util/Log;->w(Ljava/lang/String;Ljava/lang/String;Ljava/lang/Throwable;)I

    goto :goto_6

    .line 739
    .end local v6           #e:Ljava/io/IOException;
    :catch_6
    move-exception v6

    .line 740
    .restart local v6       #e:Ljava/io/IOException;
    const-string v3, "FootprintUtils"

    invoke-virtual {v6}, Ljava/io/IOException;->getMessage()Ljava/lang/String;

    move-result-object v3

    invoke-static {v8, v3, v6}, Landroid/util/Log;->w(Ljava/lang/String;Ljava/lang/String;Ljava/lang/Throwable;)I

    goto :goto_7
.end method

.method public static defaultStr(Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String;
    .locals 1
    .parameter "sourceStr"
    .parameter "defaultStr"

    .prologue
    .line 332
    if-nez p0, :cond_0

    move-object v0, p1

    :goto_0
    return-object v0

    :cond_0
    move-object v0, p0

    goto :goto_0
.end method

.method public static deleteFootprint(Landroid/content/Context;Lcom/htc/android/footprints/vo/Footprint;)V
    .locals 2
    .parameter "ctx"
    .parameter "data"

    .prologue
    .line 648
    const/4 v0, 0x0

    .line 649
    .local v0, deleteFile:Ljava/io/File;
    iget-object v1, p1, Lcom/htc/android/footprints/vo/Footprint;->mAudioPath:Ljava/lang/String;

    invoke-static {v1}, Lcom/htc/android/footprints/utils/FootprintUtils;->checkAudioData(Ljava/lang/String;)Z

    move-result v1

    if-eqz v1, :cond_0

    .line 650
    new-instance v0, Ljava/io/File;

    .end local v0           #deleteFile:Ljava/io/File;
    iget-object v1, p1, Lcom/htc/android/footprints/vo/Footprint;->mAudioPath:Ljava/lang/String;

    invoke-direct {v0, v1}, Ljava/io/File;-><init>(Ljava/lang/String;)V

    .line 651
    .restart local v0       #deleteFile:Ljava/io/File;
    invoke-virtual {v0}, Ljava/io/File;->delete()Z

    .line 653
    :cond_0
    iget-object v1, p1, Lcom/htc/android/footprints/vo/Footprint;->mPicPath:Ljava/lang/String;

    invoke-static {v1}, Lcom/htc/android/footprints/utils/FootprintUtils;->checkPhotoData(Ljava/lang/String;)Z

    move-result v1

    if-eqz v1, :cond_1

    .line 654
    new-instance v0, Ljava/io/File;

    .end local v0           #deleteFile:Ljava/io/File;
    iget-object v1, p1, Lcom/htc/android/footprints/vo/Footprint;->mPicPath:Ljava/lang/String;

    invoke-direct {v0, v1}, Ljava/io/File;-><init>(Ljava/lang/String;)V

    .line 655
    .restart local v0       #deleteFile:Ljava/io/File;
    invoke-virtual {v0}, Ljava/io/File;->delete()Z

    .line 657
    :cond_1
    const/4 v0, 0x0

    .line 658
    invoke-static {p0}, Lcom/htc/android/footprints/provider/FootprintManager;->getInstance(Landroid/content/Context;)Lcom/htc/android/footprints/provider/FootprintManager;

    move-result-object v1

    invoke-virtual {v1, p1}, Lcom/htc/android/footprints/provider/FootprintManager;->removeFootprint(Lcom/htc/android/footprints/vo/Footprint;)V

    .line 659
    return-void
.end method

.method public static deleteFootprint(Landroid/content/Context;[Lcom/htc/android/footprints/vo/Footprint;)V
    .locals 4
    .parameter "ctx"
    .parameter "data"

    .prologue
    .line 662
    move-object v0, p1

    .local v0, arr$:[Lcom/htc/android/footprints/vo/Footprint;
    array-length v3, v0

    .local v3, len$:I
    const/4 v2, 0x0

    .local v2, i$:I
    :goto_0
    if-ge v2, v3, :cond_0

    aget-object v1, v0, v2

    .line 663
    .local v1, f:Lcom/htc/android/footprints/vo/Footprint;
    invoke-static {p0, v1}, Lcom/htc/android/footprints/utils/FootprintUtils;->deleteFootprint(Landroid/content/Context;Lcom/htc/android/footprints/vo/Footprint;)V

    .line 662
    add-int/lit8 v2, v2, 0x1

    goto :goto_0

    .line 665
    .end local v1           #f:Lcom/htc/android/footprints/vo/Footprint;
    :cond_0
    return-void
.end method

.method public static exportKMZ(Landroid/app/Activity;Ljava/lang/String;[Lcom/htc/android/footprints/vo/Footprint;)V
    .locals 2
    .parameter "activity"
    .parameter "additionName"
    .parameter "footprints"

    .prologue
    .line 136
    const/4 v1, 0x1

    invoke-static {v1}, Lcom/htc/android/footprints/utils/camera/FootprintImageManager;->hasStorage(Z)Z

    move-result v1

    if-eqz v1, :cond_0

    .line 137
    new-instance v0, Lcom/htc/android/footprints/commonui/ExportDialog;

    invoke-direct {v0, p0}, Lcom/htc/android/footprints/commonui/ExportDialog;-><init>(Landroid/content/Context;)V

    .line 139
    .local v0, dialog:Lcom/htc/android/footprints/commonui/ExportDialog;
    invoke-virtual {v0}, Lcom/htc/android/footprints/commonui/ExportDialog;->show()V

    .line 141
    new-instance v1, Lcom/htc/android/footprints/utils/FootprintUtils$1;

    invoke-direct {v1, p1, p0, v0, p2}, Lcom/htc/android/footprints/utils/FootprintUtils$1;-><init>(Ljava/lang/String;Landroid/app/Activity;Lcom/htc/android/footprints/commonui/ExportDialog;[Lcom/htc/android/footprints/vo/Footprint;)V

    invoke-virtual {v1}, Lcom/htc/android/footprints/utils/FootprintUtils$1;->start()V

    .line 191
    .end local v0           #dialog:Lcom/htc/android/footprints/commonui/ExportDialog;
    :cond_0
    return-void
.end method

.method public static forceSync(Landroid/content/ContentResolver;Ljava/lang/String;)V
    .locals 2
    .parameter "cr"
    .parameter "filename"

    .prologue
    .line 615
    new-instance v0, Ljava/lang/Thread;

    new-instance v1, Lcom/htc/android/footprints/utils/FootprintUtils$2;

    invoke-direct {v1, p1, p0}, Lcom/htc/android/footprints/utils/FootprintUtils$2;-><init>(Ljava/lang/String;Landroid/content/ContentResolver;)V

    invoke-direct {v0, v1}, Ljava/lang/Thread;-><init>(Ljava/lang/Runnable;)V

    invoke-virtual {v0}, Ljava/lang/Thread;->start()V

    .line 638
    return-void
.end method

.method public static generateMD5(Ljava/lang/String;)Ljava/lang/String;
    .locals 8
    .parameter "input_data"

    .prologue
    const-string v7, "MD5"

    .line 873
    :try_start_0
    const-string v5, "MD5"

    invoke-static {v5}, Ljava/security/MessageDigest;->getInstance(Ljava/lang/String;)Ljava/security/MessageDigest;

    move-result-object v1

    .line 874
    .local v1, md:Ljava/security/MessageDigest;
    invoke-virtual {p0}, Ljava/lang/String;->getBytes()[B

    move-result-object v5

    invoke-virtual {v1, v5}, Ljava/security/MessageDigest;->digest([B)[B

    move-result-object v3

    .line 875
    .local v3, messageDigest:[B
    new-instance v4, Ljava/math/BigInteger;

    const/4 v5, 0x1

    invoke-direct {v4, v5, v3}, Ljava/math/BigInteger;-><init>(I[B)V

    .line 876
    .local v4, number:Ljava/math/BigInteger;
    const/16 v5, 0x10

    invoke-virtual {v4, v5}, Ljava/math/BigInteger;->toString(I)Ljava/lang/String;

    move-result-object v2

    .line 878
    .local v2, md5:Ljava/lang/String;
    :goto_0
    invoke-virtual {v2}, Ljava/lang/String;->length()I

    move-result v5

    const/16 v6, 0x20

    if-ge v5, v6, :cond_0

    .line 879
    new-instance v5, Ljava/lang/StringBuilder;

    invoke-direct {v5}, Ljava/lang/StringBuilder;-><init>()V

    const-string v6, "0"

    invoke-virtual {v5, v6}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v5

    invoke-virtual {v5, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v5

    invoke-virtual {v5}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
    :try_end_0
    .catch Ljava/security/NoSuchAlgorithmException; {:try_start_0 .. :try_end_0} :catch_0

    move-result-object v2

    goto :goto_0

    :cond_0
    move-object v5, v2

    .line 883
    .end local v1           #md:Ljava/security/MessageDigest;
    .end local v2           #md5:Ljava/lang/String;
    .end local v3           #messageDigest:[B
    .end local v4           #number:Ljava/math/BigInteger;
    :goto_1
    return-object v5

    .line 881
    :catch_0
    move-exception v5

    move-object v0, v5

    .line 882
    .local v0, e:Ljava/security/NoSuchAlgorithmException;
    const-string v5, "MD5"

    invoke-virtual {v0}, Ljava/security/NoSuchAlgorithmException;->getMessage()Ljava/lang/String;

    move-result-object v5

    invoke-static {v7, v5}, Landroid/util/Log;->e(Ljava/lang/String;Ljava/lang/String;)I

    .line 883
    const/4 v5, 0x0

    goto :goto_1
.end method

.method public static getAddressByLocale(Landroid/location/Address;Landroid/content/Context;)Ljava/lang/String;
    .locals 10
    .parameter "address"
    .parameter "context"

    .prologue
    const-string v9, ""

    .line 305
    new-instance v4, Ljava/lang/StringBuilder;

    invoke-direct {v4}, Ljava/lang/StringBuilder;-><init>()V

    .line 306
    .local v4, result:Ljava/lang/StringBuilder;
    invoke-virtual {p0}, Landroid/location/Address;->getCountryCode()Ljava/lang/String;

    move-result-object v7

    const-string v8, ""

    invoke-static {v7, v9}, Lcom/htc/android/footprints/utils/FootprintUtils;->defaultStr(Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String;

    move-result-object v2

    .line 307
    .local v2, countryCode:Ljava/lang/String;
    invoke-virtual {p0}, Landroid/location/Address;->getCountryName()Ljava/lang/String;

    move-result-object v7

    const-string v8, ""

    invoke-static {v7, v9}, Lcom/htc/android/footprints/utils/FootprintUtils;->defaultStr(Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String;

    move-result-object v1

    .line 308
    .local v1, country:Ljava/lang/String;
    invoke-virtual {p0}, Landroid/location/Address;->getAdminArea()Ljava/lang/String;

    move-result-object v7

    const-string v8, ""

    invoke-static {v7, v9}, Lcom/htc/android/footprints/utils/FootprintUtils;->defaultStr(Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String;

    move-result-object v0

    .line 309
    .local v0, adminArea:Ljava/lang/String;
    invoke-virtual {p0}, Landroid/location/Address;->getSubAdminArea()Ljava/lang/String;

    move-result-object v7

    const-string v8, ""

    invoke-static {v7, v9}, Lcom/htc/android/footprints/utils/FootprintUtils;->defaultStr(Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String;

    move-result-object v5

    .line 310
    .local v5, subAdminArea:Ljava/lang/String;
    invoke-virtual {p0}, Landroid/location/Address;->getLocality()Ljava/lang/String;

    move-result-object v7

    const-string v8, ""

    invoke-static {v7, v9}, Lcom/htc/android/footprints/utils/FootprintUtils;->defaultStr(Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String;

    move-result-object v3

    .line 311
    .local v3, locality:Ljava/lang/String;
    invoke-virtual {p0}, Landroid/location/Address;->getThoroughfare()Ljava/lang/String;

    move-result-object v7

    const-string v8, ""

    invoke-static {v7, v9}, Lcom/htc/android/footprints/utils/FootprintUtils;->defaultStr(Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String;

    move-result-object v6

    .line 315
    .local v6, thoroughfare:Ljava/lang/String;
    invoke-virtual {v4, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    .line 316
    invoke-virtual {v4, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    .line 317
    invoke-virtual {v4, v0}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    .line 318
    invoke-virtual {v4, v5}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    .line 319
    invoke-virtual {v4, v3}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    .line 320
    invoke-virtual {v4, v6}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    .line 327
    invoke-virtual {v4}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v7

    return-object v7
.end method

.method public static getBrightPreferences(Landroid/content/Context;)I
    .locals 3
    .parameter "context"

    .prologue
    .line 288
    const-string v1, "Footprints"

    const/4 v2, 0x0

    invoke-virtual {p0, v1, v2}, Landroid/content/Context;->getSharedPreferences(Ljava/lang/String;I)Landroid/content/SharedPreferences;

    move-result-object v0

    .line 289
    .local v0, pref:Landroid/content/SharedPreferences;
    const-string v1, "FOOTPRINTS_CAMERA_BRIGHT"

    const/4 v2, 0x5

    invoke-interface {v0, v1, v2}, Landroid/content/SharedPreferences;->getInt(Ljava/lang/String;I)I

    move-result v1

    return v1
.end method

.method public static getCategoryIcon(Landroid/content/Context;Ljava/lang/String;)Landroid/graphics/drawable/Drawable;
    .locals 2
    .parameter "context"
    .parameter "categoryName"

    .prologue
    .line 785
    invoke-virtual {p0}, Landroid/content/Context;->getResources()Landroid/content/res/Resources;

    move-result-object v0

    .line 787
    .local v0, r:Landroid/content/res/Resources;
    const-string v1, "favorite"

    invoke-virtual {p1, v1}, Ljava/lang/String;->equalsIgnoreCase(Ljava/lang/String;)Z

    move-result v1

    if-eqz v1, :cond_0

    .line 788
    const v1, 0x7f0200c6

    invoke-virtual {v0, v1}, Landroid/content/res/Resources;->getDrawable(I)Landroid/graphics/drawable/Drawable;

    move-result-object v1

    .line 798
    :goto_0
    return-object v1

    .line 789
    :cond_0
    const-string v1, "shopping"

    invoke-virtual {p1, v1}, Ljava/lang/String;->equalsIgnoreCase(Ljava/lang/String;)Z

    move-result v1

    if-eqz v1, :cond_1

    .line 790
    const v1, 0x7f0200eb

    invoke-virtual {v0, v1}, Landroid/content/res/Resources;->getDrawable(I)Landroid/graphics/drawable/Drawable;

    move-result-object v1

    goto :goto_0

    .line 791
    :cond_1
    const-string v1, "dining"

    invoke-virtual {p1, v1}, Ljava/lang/String;->equalsIgnoreCase(Ljava/lang/String;)Z

    move-result v1

    if-eqz v1, :cond_2

    .line 792
    const v1, 0x7f0200e9

    invoke-virtual {v0, v1}, Landroid/content/res/Resources;->getDrawable(I)Landroid/graphics/drawable/Drawable;

    move-result-object v1

    goto :goto_0

    .line 793
    :cond_2
    const-string v1, "leisure"

    invoke-virtual {p1, v1}, Ljava/lang/String;->equalsIgnoreCase(Ljava/lang/String;)Z

    move-result v1

    if-eqz v1, :cond_3

    .line 794
    const v1, 0x7f0200de

    invoke-virtual {v0, v1}, Landroid/content/res/Resources;->getDrawable(I)Landroid/graphics/drawable/Drawable;

    move-result-object v1

    goto :goto_0

    .line 795
    :cond_3
    const-string v1, "other"

    invoke-virtual {p1, v1}, Ljava/lang/String;->equalsIgnoreCase(Ljava/lang/String;)Z

    move-result v1

    if-eqz v1, :cond_4

    .line 796
    const v1, 0x7f0200e8

    invoke-virtual {v0, v1}, Landroid/content/res/Resources;->getDrawable(I)Landroid/graphics/drawable/Drawable;

    move-result-object v1

    goto :goto_0

    .line 798
    :cond_4
    const v1, 0x7f020001

    invoke-virtual {v0, v1}, Landroid/content/res/Resources;->getDrawable(I)Landroid/graphics/drawable/Drawable;

    move-result-object v1

    goto :goto_0
.end method

.method public static getCategoryOverlayIcon(Landroid/content/Context;Ljava/lang/String;)Landroid/graphics/drawable/Drawable;
    .locals 2
    .parameter "context"
    .parameter "categoryName"

    .prologue
    .line 765
    invoke-virtual {p0}, Landroid/content/Context;->getResources()Landroid/content/res/Resources;

    move-result-object v0

    .line 766
    .local v0, r:Landroid/content/res/Resources;
    const-string v1, "favorite"

    invoke-virtual {p1, v1}, Ljava/lang/String;->equalsIgnoreCase(Ljava/lang/String;)Z

    move-result v1

    if-eqz v1, :cond_0

    .line 767
    const v1, 0x7f0200f9

    invoke-virtual {v0, v1}, Landroid/content/res/Resources;->getDrawable(I)Landroid/graphics/drawable/Drawable;

    move-result-object v1

    .line 777
    :goto_0
    return-object v1

    .line 768
    :cond_0
    const-string v1, "shopping"

    invoke-virtual {p1, v1}, Ljava/lang/String;->equalsIgnoreCase(Ljava/lang/String;)Z

    move-result v1

    if-eqz v1, :cond_1

    .line 769
    const v1, 0x7f0200fd

    invoke-virtual {v0, v1}, Landroid/content/res/Resources;->getDrawable(I)Landroid/graphics/drawable/Drawable;

    move-result-object v1

    goto :goto_0

    .line 770
    :cond_1
    const-string v1, "dining"

    invoke-virtual {p1, v1}, Ljava/lang/String;->equalsIgnoreCase(Ljava/lang/String;)Z

    move-result v1

    if-eqz v1, :cond_2

    .line 771
    const v1, 0x7f0200fc

    invoke-virtual {v0, v1}, Landroid/content/res/Resources;->getDrawable(I)Landroid/graphics/drawable/Drawable;

    move-result-object v1

    goto :goto_0

    .line 772
    :cond_2
    const-string v1, "leisure"

    invoke-virtual {p1, v1}, Ljava/lang/String;->equalsIgnoreCase(Ljava/lang/String;)Z

    move-result v1

    if-eqz v1, :cond_3

    .line 773
    const v1, 0x7f0200fa

    invoke-virtual {v0, v1}, Landroid/content/res/Resources;->getDrawable(I)Landroid/graphics/drawable/Drawable;

    move-result-object v1

    goto :goto_0

    .line 774
    :cond_3
    const-string v1, "other"

    invoke-virtual {p1, v1}, Ljava/lang/String;->equalsIgnoreCase(Ljava/lang/String;)Z

    move-result v1

    if-eqz v1, :cond_4

    .line 775
    const v1, 0x7f0200fb

    invoke-virtual {v0, v1}, Landroid/content/res/Resources;->getDrawable(I)Landroid/graphics/drawable/Drawable;

    move-result-object v1

    goto :goto_0

    .line 777
    :cond_4
    const v1, 0x7f0200f8

    invoke-virtual {v0, v1}, Landroid/content/res/Resources;->getDrawable(I)Landroid/graphics/drawable/Drawable;

    move-result-object v1

    goto :goto_0
.end method

.method public static getDBPathOnSD()Ljava/lang/String;
    .locals 2

    .prologue
    .line 1130
    new-instance v0, Ljava/lang/StringBuilder;

    invoke-direct {v0}, Ljava/lang/StringBuilder;-><init>()V

    invoke-static {}, Lcom/htc/android/footprints/utils/StorageUtil;->getFootprintStorageDirectory()Ljava/lang/String;

    move-result-object v1

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    sget-object v1, Ljava/io/File;->separator:Ljava/lang/String;

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    const-string v1, "footprints.db"

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v0

    return-object v0
.end method

.method public static getDateWithSerialNo(Landroid/content/Context;)Ljava/lang/String;
    .locals 10
    .parameter "context"

    .prologue
    const/4 v8, 0x0

    const-string v9, "SERIAL"

    .line 207
    new-instance v0, Ljava/text/DecimalFormat;

    const-string v6, "000"

    invoke-direct {v0, v6}, Ljava/text/DecimalFormat;-><init>(Ljava/lang/String;)V

    .line 210
    .local v0, df:Ljava/text/DecimalFormat;
    const-string v6, "Footprints"

    invoke-virtual {p0, v6, v8}, Landroid/content/Context;->getSharedPreferences(Ljava/lang/String;I)Landroid/content/SharedPreferences;

    move-result-object v5

    .line 212
    .local v5, settings:Landroid/content/SharedPreferences;
    invoke-interface {v5}, Landroid/content/SharedPreferences;->edit()Landroid/content/SharedPreferences$Editor;

    move-result-object v1

    .line 213
    .local v1, editor:Landroid/content/SharedPreferences$Editor;
    const-string v6, "DATE"

    const-string v7, ""

    invoke-interface {v5, v6, v7}, Landroid/content/SharedPreferences;->getString(Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String;

    move-result-object v2

    .line 214
    .local v2, pDate:Ljava/lang/String;
    const-string v6, "SERIAL"

    invoke-interface {v5, v9, v8}, Landroid/content/SharedPreferences;->getInt(Ljava/lang/String;I)I

    move-result v4

    .line 222
    .local v4, serNo:I
    add-int/lit8 v4, v4, 0x1

    int-to-long v6, v4

    invoke-virtual {v0, v6, v7}, Ljava/text/DecimalFormat;->format(J)Ljava/lang/String;

    move-result-object v3

    .line 224
    .local v3, result:Ljava/lang/String;
    const-string v6, "SERIAL"

    invoke-interface {v1, v9, v4}, Landroid/content/SharedPreferences$Editor;->putInt(Ljava/lang/String;I)Landroid/content/SharedPreferences$Editor;

    .line 225
    invoke-interface {v1}, Landroid/content/SharedPreferences$Editor;->commit()Z

    .line 226
    return-object v3
.end method

.method public static getDefaultName(Landroid/content/Context;)Ljava/lang/String;
    .locals 5
    .parameter "context"

    .prologue
    .line 122
    new-instance v0, Ljava/text/DecimalFormat;

    const-string v2, " ##000"

    invoke-direct {v0, v2}, Ljava/text/DecimalFormat;-><init>(Ljava/lang/String;)V

    .line 125
    .local v0, mf:Ljava/text/DecimalFormat;
    invoke-static {p0}, Lcom/htc/android/footprints/utils/SettingInfo;->getInstance(Landroid/content/Context;)Lcom/htc/android/footprints/utils/SettingInfo;

    move-result-object v2

    invoke-virtual {v2}, Lcom/htc/android/footprints/utils/SettingInfo;->getNewSerialNumber()I

    move-result v1

    .line 126
    .local v1, size:I
    new-instance v2, Ljava/lang/StringBuilder;

    invoke-direct {v2}, Ljava/lang/StringBuilder;-><init>()V

    const-string v3, "Footprints "

    invoke-virtual {v2, v3}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v2

    int-to-long v3, v1

    invoke-virtual {v0, v3, v4}, Ljava/text/DecimalFormat;->format(J)Ljava/lang/String;

    move-result-object v3

    invoke-virtual {v2, v3}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v2

    invoke-virtual {v2}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v2

    return-object v2
.end method

.method public static getExtDBVersion()I
    .locals 8

    .prologue
    .line 1247
    const/4 v3, -0x1

    .line 1248
    .local v3, version:I
    new-instance v1, Ljava/io/File;

    invoke-static {}, Lcom/htc/android/footprints/utils/FootprintUtils;->getDBPathOnSD()Ljava/lang/String;

    move-result-object v4

    invoke-direct {v1, v4}, Ljava/io/File;-><init>(Ljava/lang/String;)V

    .line 1249
    .local v1, dbFile:Ljava/io/File;
    if-eqz v1, :cond_0

    invoke-virtual {v1}, Ljava/io/File;->exists()Z

    move-result v4

    if-eqz v4, :cond_0

    invoke-virtual {v1}, Ljava/io/File;->length()J

    move-result-wide v4

    const-wide/16 v6, 0x0

    cmp-long v4, v4, v6

    if-lez v4, :cond_0

    .line 1250
    const/4 v0, 0x0

    .line 1252
    .local v0, db:Landroid/database/sqlite/SQLiteDatabase;
    :try_start_0
    invoke-static {}, Lcom/htc/android/footprints/utils/FootprintUtils;->getDBPathOnSD()Ljava/lang/String;

    move-result-object v4

    const/4 v5, 0x0

    const/4 v6, 0x1

    invoke-static {v4, v5, v6}, Landroid/database/sqlite/SQLiteDatabase;->openDatabase(Ljava/lang/String;Landroid/database/sqlite/SQLiteDatabase$CursorFactory;I)Landroid/database/sqlite/SQLiteDatabase;

    move-result-object v0

    .line 1253
    invoke-virtual {v0}, Landroid/database/sqlite/SQLiteDatabase;->getVersion()I
    :try_end_0
    .catchall {:try_start_0 .. :try_end_0} :catchall_0
    .catch Landroid/database/sqlite/SQLiteException; {:try_start_0 .. :try_end_0} :catch_0

    move-result v3

    .line 1257
    invoke-virtual {v0}, Landroid/database/sqlite/SQLiteDatabase;->close()V

    .line 1258
    const/4 v0, 0x0

    .line 1261
    .end local v0           #db:Landroid/database/sqlite/SQLiteDatabase;
    :cond_0
    :goto_0
    return v3

    .line 1254
    .restart local v0       #db:Landroid/database/sqlite/SQLiteDatabase;
    :catch_0
    move-exception v4

    move-object v2, v4

    .line 1255
    .local v2, e:Landroid/database/sqlite/SQLiteException;
    :try_start_1
    invoke-virtual {v2}, Landroid/database/sqlite/SQLiteException;->printStackTrace()V
    :try_end_1
    .catchall {:try_start_1 .. :try_end_1} :catchall_0

    .line 1257
    invoke-virtual {v0}, Landroid/database/sqlite/SQLiteDatabase;->close()V

    .line 1258
    const/4 v0, 0x0

    .line 1259
    goto :goto_0

    .line 1257
    .end local v2           #e:Landroid/database/sqlite/SQLiteException;
    :catchall_0
    move-exception v4

    invoke-virtual {v0}, Landroid/database/sqlite/SQLiteDatabase;->close()V

    .line 1258
    const/4 v0, 0x0

    throw v4
.end method

.method public static getFormatedLat(I)Ljava/lang/String;
    .locals 7
    .parameter "latE6"

    .prologue
    .line 66
    int-to-double v0, p0

    const-wide v2, 0x412e848000000000L

    div-double/2addr v0, v2

    .line 68
    .local v0, lat:D
    const/4 p0, 0x2

    invoke-static {v0, v1, p0}, Landroid/location/Location;->convert(DI)Ljava/lang/String;

    .end local p0
    move-result-object p0

    .line 69
    .local p0, latStr:Ljava/lang/String;
    const-string v0, ":"

    .end local v0           #lat:D
    invoke-virtual {p0, v0}, Ljava/lang/String;->split(Ljava/lang/String;)[Ljava/lang/String;

    move-result-object v0

    .line 71
    .local v0, latArr:[Ljava/lang/String;
    new-instance p0, Ljava/text/DecimalFormat;

    .end local p0           #latStr:Ljava/lang/String;
    const-string v1, "###.##"

    invoke-direct {p0, v1}, Ljava/text/DecimalFormat;-><init>(Ljava/lang/String;)V

    .line 72
    .local p0, secFormat:Ljava/text/DecimalFormat;
    new-instance v1, Ljava/text/MessageFormat;

    const-string p0, "{0}\u00b0 {1}\'\' {2}\" {3}"

    .end local p0           #secFormat:Ljava/text/DecimalFormat;
    invoke-direct {v1, p0}, Ljava/text/MessageFormat;-><init>(Ljava/lang/String;)V

    .line 73
    .local v1, mformat:Ljava/text/MessageFormat;
    const/4 p0, 0x4

    new-array p0, p0, [Ljava/lang/String;

    .line 74
    .local p0, argLat:[Ljava/lang/String;
    const/4 v2, 0x0

    const/4 v3, 0x0

    aget-object v3, v0, v3

    invoke-static {v3}, Ljava/lang/Integer;->parseInt(Ljava/lang/String;)I

    move-result v3

    invoke-static {v3}, Ljava/lang/Math;->abs(I)I

    move-result v3

    invoke-static {v3}, Ljava/lang/String;->valueOf(I)Ljava/lang/String;

    move-result-object v3

    aput-object v3, p0, v2

    .line 75
    const/4 v2, 0x1

    const/4 v3, 0x1

    aget-object v3, v0, v3

    aput-object v3, p0, v2

    .line 77
    const/4 v2, 0x2

    aget-object v2, v0, v2

    const-string v3, "\\."

    invoke-virtual {v2, v3}, Ljava/lang/String;->split(Ljava/lang/String;)[Ljava/lang/String;

    move-result-object v2

    .line 78
    .local v2, subStr:[Ljava/lang/String;
    new-instance v3, Ljava/lang/String;

    const-string v4, "0"

    invoke-direct {v3, v4}, Ljava/lang/String;-><init>(Ljava/lang/String;)V

    .line 79
    .local v3, tmpStr:Ljava/lang/String;
    array-length v4, v2

    const/4 v5, 0x2

    if-lt v4, v5, :cond_0

    .line 80
    const/4 v3, 0x1

    aget-object v3, v2, v3

    .end local v3           #tmpStr:Ljava/lang/String;
    invoke-virtual {v3}, Ljava/lang/String;->length()I

    move-result v3

    const/4 v4, 0x2

    if-le v3, v4, :cond_1

    .line 81
    const/4 v3, 0x1

    aget-object v3, v2, v3

    const/4 v4, 0x0

    const/4 v5, 0x2

    invoke-virtual {v3, v4, v5}, Ljava/lang/String;->substring(II)Ljava/lang/String;

    move-result-object v3

    .line 86
    .restart local v3       #tmpStr:Ljava/lang/String;
    :cond_0
    :goto_0
    const/4 v4, 0x2

    new-instance v5, Ljava/lang/StringBuilder;

    invoke-direct {v5}, Ljava/lang/StringBuilder;-><init>()V

    const/4 v6, 0x0

    aget-object v2, v2, v6

    .end local v2           #subStr:[Ljava/lang/String;
    invoke-virtual {v5, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v2

    const-string v5, "."

    invoke-virtual {v2, v5}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v2

    invoke-virtual {v2, v3}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v2

    invoke-virtual {v2}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v2

    aput-object v2, p0, v4

    .line 88
    const/4 v2, 0x3

    const/4 v3, 0x0

    aget-object v0, v0, v3

    .end local v0           #latArr:[Ljava/lang/String;
    .end local v3           #tmpStr:Ljava/lang/String;
    invoke-static {v0}, Ljava/lang/Integer;->parseInt(Ljava/lang/String;)I

    move-result v0

    if-ltz v0, :cond_2

    const-string v0, "N"

    :goto_1
    aput-object v0, p0, v2

    .line 89
    invoke-virtual {v1, p0}, Ljava/text/MessageFormat;->format(Ljava/lang/Object;)Ljava/lang/String;

    move-result-object p0

    .end local p0           #argLat:[Ljava/lang/String;
    return-object p0

    .line 83
    .restart local v0       #latArr:[Ljava/lang/String;
    .restart local v2       #subStr:[Ljava/lang/String;
    .restart local p0       #argLat:[Ljava/lang/String;
    :cond_1
    const/4 v3, 0x1

    aget-object v3, v2, v3

    .restart local v3       #tmpStr:Ljava/lang/String;
    goto :goto_0

    .line 88
    .end local v0           #latArr:[Ljava/lang/String;
    .end local v2           #subStr:[Ljava/lang/String;
    .end local v3           #tmpStr:Ljava/lang/String;
    :cond_2
    const-string v0, "S"

    goto :goto_1
.end method

.method public static getFormatedLon(I)Ljava/lang/String;
    .locals 7
    .parameter "lonE6"

    .prologue
    .line 93
    int-to-double v0, p0

    const-wide v2, 0x412e848000000000L

    div-double/2addr v0, v2

    .line 94
    .local v0, lon:D
    new-instance p0, Ljava/text/DecimalFormat;

    .end local p0
    const-string v2, "###.##"

    invoke-direct {p0, v2}, Ljava/text/DecimalFormat;-><init>(Ljava/lang/String;)V

    .line 95
    .local p0, secFormat:Ljava/text/DecimalFormat;
    new-instance v2, Ljava/text/MessageFormat;

    const-string p0, "{0}\u00b0 {1}\'\' {2}\" {3}"

    .end local p0           #secFormat:Ljava/text/DecimalFormat;
    invoke-direct {v2, p0}, Ljava/text/MessageFormat;-><init>(Ljava/lang/String;)V

    .line 96
    .local v2, mformat:Ljava/text/MessageFormat;
    const/4 p0, 0x2

    invoke-static {v0, v1, p0}, Landroid/location/Location;->convert(DI)Ljava/lang/String;

    move-result-object p0

    .line 97
    .local p0, lonStr:Ljava/lang/String;
    const-string v0, ":"

    .end local v0           #lon:D
    invoke-virtual {p0, v0}, Ljava/lang/String;->split(Ljava/lang/String;)[Ljava/lang/String;

    move-result-object v0

    .line 98
    .local v0, lonArr:[Ljava/lang/String;
    const/4 p0, 0x4

    new-array p0, p0, [Ljava/lang/String;

    .line 99
    .local p0, argLon:[Ljava/lang/String;
    const/4 v1, 0x0

    const/4 v3, 0x0

    aget-object v3, v0, v3

    invoke-static {v3}, Ljava/lang/Integer;->parseInt(Ljava/lang/String;)I

    move-result v3

    invoke-static {v3}, Ljava/lang/Math;->abs(I)I

    move-result v3

    invoke-static {v3}, Ljava/lang/String;->valueOf(I)Ljava/lang/String;

    move-result-object v3

    aput-object v3, p0, v1

    .line 100
    const/4 v1, 0x1

    const/4 v3, 0x1

    aget-object v3, v0, v3

    aput-object v3, p0, v1

    .line 102
    const/4 v1, 0x2

    aget-object v1, v0, v1

    const-string v3, "\\."

    invoke-virtual {v1, v3}, Ljava/lang/String;->split(Ljava/lang/String;)[Ljava/lang/String;

    move-result-object v1

    .line 103
    .local v1, subStr:[Ljava/lang/String;
    new-instance v3, Ljava/lang/String;

    const-string v4, "0"

    invoke-direct {v3, v4}, Ljava/lang/String;-><init>(Ljava/lang/String;)V

    .line 104
    .local v3, tmpStr:Ljava/lang/String;
    array-length v4, v1

    const/4 v5, 0x2

    if-lt v4, v5, :cond_0

    .line 105
    const/4 v3, 0x1

    aget-object v3, v1, v3

    .end local v3           #tmpStr:Ljava/lang/String;
    invoke-virtual {v3}, Ljava/lang/String;->length()I

    move-result v3

    const/4 v4, 0x2

    if-le v3, v4, :cond_1

    .line 106
    const/4 v3, 0x1

    aget-object v3, v1, v3

    const/4 v4, 0x0

    const/4 v5, 0x2

    invoke-virtual {v3, v4, v5}, Ljava/lang/String;->substring(II)Ljava/lang/String;

    move-result-object v3

    .line 111
    .restart local v3       #tmpStr:Ljava/lang/String;
    :cond_0
    :goto_0
    const/4 v4, 0x2

    new-instance v5, Ljava/lang/StringBuilder;

    invoke-direct {v5}, Ljava/lang/StringBuilder;-><init>()V

    const/4 v6, 0x0

    aget-object v1, v1, v6

    .end local v1           #subStr:[Ljava/lang/String;
    invoke-virtual {v5, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v1

    const-string v5, "."

    invoke-virtual {v1, v5}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v1

    invoke-virtual {v1, v3}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v1

    invoke-virtual {v1}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v1

    aput-object v1, p0, v4

    .line 113
    const/4 v1, 0x3

    const/4 v3, 0x0

    aget-object v0, v0, v3

    .end local v0           #lonArr:[Ljava/lang/String;
    .end local v3           #tmpStr:Ljava/lang/String;
    invoke-static {v0}, Ljava/lang/Integer;->parseInt(Ljava/lang/String;)I

    move-result v0

    if-ltz v0, :cond_2

    const-string v0, "E"

    :goto_1
    aput-object v0, p0, v1

    .line 115
    invoke-virtual {v2, p0}, Ljava/text/MessageFormat;->format(Ljava/lang/Object;)Ljava/lang/String;

    move-result-object p0

    .end local p0           #argLon:[Ljava/lang/String;
    return-object p0

    .line 108
    .restart local v0       #lonArr:[Ljava/lang/String;
    .restart local v1       #subStr:[Ljava/lang/String;
    .restart local p0       #argLon:[Ljava/lang/String;
    :cond_1
    const/4 v3, 0x1

    aget-object v3, v1, v3

    .restart local v3       #tmpStr:Ljava/lang/String;
    goto :goto_0

    .line 113
    .end local v0           #lonArr:[Ljava/lang/String;
    .end local v1           #subStr:[Ljava/lang/String;
    .end local v3           #tmpStr:Ljava/lang/String;
    :cond_2
    const-string v0, "W"

    goto :goto_1
.end method

.method public static getInverse(Landroid/graphics/drawable/Drawable;)Landroid/graphics/drawable/Drawable;
    .locals 5
    .parameter "d"

    .prologue
    .line 194
    invoke-virtual {p0}, Landroid/graphics/drawable/Drawable;->getIntrinsicWidth()I

    move-result v2

    invoke-virtual {p0}, Landroid/graphics/drawable/Drawable;->getIntrinsicHeight()I

    move-result v3

    sget-object v4, Landroid/graphics/Bitmap$Config;->ARGB_8888:Landroid/graphics/Bitmap$Config;

    invoke-static {v2, v3, v4}, Landroid/graphics/Bitmap;->createBitmap(IILandroid/graphics/Bitmap$Config;)Landroid/graphics/Bitmap;

    move-result-object v1

    .line 197
    .local v1, newBmp:Landroid/graphics/Bitmap;
    new-instance v0, Landroid/graphics/Canvas;

    invoke-direct {v0, v1}, Landroid/graphics/Canvas;-><init>(Landroid/graphics/Bitmap;)V

    .line 199
    .local v0, canvas:Landroid/graphics/Canvas;
    const v2, -0x111112

    sget-object v3, Landroid/graphics/PorterDuff$Mode;->SRC_IN:Landroid/graphics/PorterDuff$Mode;

    invoke-virtual {p0, v2, v3}, Landroid/graphics/drawable/Drawable;->setColorFilter(ILandroid/graphics/PorterDuff$Mode;)V

    .line 200
    invoke-virtual {p0, v0}, Landroid/graphics/drawable/Drawable;->draw(Landroid/graphics/Canvas;)V

    .line 201
    invoke-virtual {p0}, Landroid/graphics/drawable/Drawable;->clearColorFilter()V

    .line 202
    new-instance v2, Landroid/graphics/drawable/BitmapDrawable;

    invoke-direct {v2, v1}, Landroid/graphics/drawable/BitmapDrawable;-><init>(Landroid/graphics/Bitmap;)V

    return-object v2
.end method

.method public static getInverseCategory(Landroid/content/Context;Ljava/lang/String;)Landroid/graphics/drawable/Drawable;
    .locals 2
    .parameter "context"
    .parameter "categoryName"

    .prologue
    .line 839
    invoke-virtual {p0}, Landroid/content/Context;->getResources()Landroid/content/res/Resources;

    move-result-object v0

    .line 841
    .local v0, r:Landroid/content/res/Resources;
    const-string v1, "favorite"

    invoke-virtual {p1, v1}, Ljava/lang/String;->equalsIgnoreCase(Ljava/lang/String;)Z

    move-result v1

    if-eqz v1, :cond_0

    .line 842
    const v1, 0x7f020084

    invoke-virtual {v0, v1}, Landroid/content/res/Resources;->getDrawable(I)Landroid/graphics/drawable/Drawable;

    move-result-object v1

    .line 852
    :goto_0
    return-object v1

    .line 843
    :cond_0
    const-string v1, "shopping"

    invoke-virtual {p1, v1}, Ljava/lang/String;->equalsIgnoreCase(Ljava/lang/String;)Z

    move-result v1

    if-eqz v1, :cond_1

    .line 844
    const v1, 0x7f020109

    invoke-virtual {v0, v1}, Landroid/content/res/Resources;->getDrawable(I)Landroid/graphics/drawable/Drawable;

    move-result-object v1

    goto :goto_0

    .line 845
    :cond_1
    const-string v1, "dining"

    invoke-virtual {p1, v1}, Ljava/lang/String;->equalsIgnoreCase(Ljava/lang/String;)Z

    move-result v1

    if-eqz v1, :cond_2

    .line 846
    const v1, 0x7f020105

    invoke-virtual {v0, v1}, Landroid/content/res/Resources;->getDrawable(I)Landroid/graphics/drawable/Drawable;

    move-result-object v1

    goto :goto_0

    .line 847
    :cond_2
    const-string v1, "leisure"

    invoke-virtual {p1, v1}, Ljava/lang/String;->equalsIgnoreCase(Ljava/lang/String;)Z

    move-result v1

    if-eqz v1, :cond_3

    .line 848
    const v1, 0x7f0200ee

    invoke-virtual {v0, v1}, Landroid/content/res/Resources;->getDrawable(I)Landroid/graphics/drawable/Drawable;

    move-result-object v1

    goto :goto_0

    .line 849
    :cond_3
    const-string v1, "other"

    invoke-virtual {p1, v1}, Ljava/lang/String;->equalsIgnoreCase(Ljava/lang/String;)Z

    move-result v1

    if-eqz v1, :cond_4

    .line 850
    const v1, 0x7f0200f6

    invoke-virtual {v0, v1}, Landroid/content/res/Resources;->getDrawable(I)Landroid/graphics/drawable/Drawable;

    move-result-object v1

    goto :goto_0

    .line 852
    :cond_4
    const/high16 v1, 0x7f02

    invoke-virtual {v0, v1}, Landroid/content/res/Resources;->getDrawable(I)Landroid/graphics/drawable/Drawable;

    move-result-object v1

    goto :goto_0
.end method

.method public static getLocationFromPicture(Landroid/content/Context;Ljava/lang/String;)Landroid/location/Location;
    .locals 5
    .parameter "context"
    .parameter "path"

    .prologue
    .line 459
    const/4 p0, 0x0

    .line 460
    .local p0, mExifData:Ljava/util/HashMap;,"Ljava/util/HashMap<Ljava/lang/String;Ljava/lang/String;>;"
    new-instance p0, Lcom/htc/android/footprints/utils/ExifInterface;

    .end local p0           #mExifData:Ljava/util/HashMap;,"Ljava/util/HashMap<Ljava/lang/String;Ljava/lang/String;>;"
    invoke-direct {p0, p1}, Lcom/htc/android/footprints/utils/ExifInterface;-><init>(Ljava/lang/String;)V

    .line 461
    .local p0, exif:Lcom/htc/android/footprints/utils/ExifInterface;
    invoke-virtual {p0}, Lcom/htc/android/footprints/utils/ExifInterface;->getAttributes()Ljava/util/HashMap;

    move-result-object v1

    .line 462
    .local v1, mExifData:Ljava/util/HashMap;,"Ljava/util/HashMap<Ljava/lang/String;Ljava/lang/String;>;"
    const-string p0, "GPSLatitude"

    .end local p0           #exif:Lcom/htc/android/footprints/utils/ExifInterface;
    invoke-virtual {v1, p0}, Ljava/util/HashMap;->get(Ljava/lang/Object;)Ljava/lang/Object;

    move-result-object p0

    check-cast p0, Ljava/lang/String;

    .line 463
    .local p0, lat:Ljava/lang/String;
    const-string p1, "GPSLongitude"

    .end local p1
    invoke-virtual {v1, p1}, Ljava/util/HashMap;->get(Ljava/lang/Object;)Ljava/lang/Object;

    move-result-object v0

    check-cast v0, Ljava/lang/String;

    .line 464
    .local v0, lon:Ljava/lang/String;
    const-string p1, "GPSLatitudeRef"

    invoke-virtual {v1, p1}, Ljava/util/HashMap;->get(Ljava/lang/Object;)Ljava/lang/Object;

    move-result-object p1

    check-cast p1, Ljava/lang/String;

    .line 465
    .local p1, latDir:Ljava/lang/String;
    const-string v2, "GPSLongitudeRef"

    invoke-virtual {v1, v2}, Ljava/util/HashMap;->get(Ljava/lang/Object;)Ljava/lang/Object;

    move-result-object v1

    .end local v1           #mExifData:Ljava/util/HashMap;,"Ljava/util/HashMap<Ljava/lang/String;Ljava/lang/String;>;"
    check-cast v1, Ljava/lang/String;

    .line 466
    .local v1, lonDir:Ljava/lang/String;
    const-string v2, "FootprintUtils"

    new-instance v3, Ljava/lang/StringBuilder;

    invoke-direct {v3}, Ljava/lang/StringBuilder;-><init>()V

    const-string v4, "read picture lat = "

    invoke-virtual {v3, v4}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v3

    invoke-virtual {v3, p0}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v3

    const-string v4, "/ lat ref = "

    invoke-virtual {v3, v4}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v3

    invoke-virtual {v3, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object p1

    .end local p1           #latDir:Ljava/lang/String;
    invoke-virtual {p1}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object p1

    invoke-static {v2, p1}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I

    .line 467
    const-string p1, "FootprintUtils"

    new-instance v2, Ljava/lang/StringBuilder;

    invoke-direct {v2}, Ljava/lang/StringBuilder;-><init>()V

    const-string v3, "read picture lon = "

    invoke-virtual {v2, v3}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v2

    invoke-virtual {v2, v0}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v2

    const-string v3, "/ lon ref = "

    invoke-virtual {v2, v3}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v2

    invoke-virtual {v2, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v1

    .end local v1           #lonDir:Ljava/lang/String;
    invoke-virtual {v1}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v1

    invoke-static {p1, v1}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I

    .line 469
    const-string p1, "lat"

    const/4 v1, 0x0

    invoke-static {p0, p1, v1}, Lcom/htc/android/footprints/utils/ExifInterface;->convertRationalLatLonToDecimalString(Ljava/lang/String;Ljava/lang/String;Z)Ljava/lang/String;

    move-result-object p0

    .line 471
    const-string p1, "lon"

    const/4 v1, 0x0

    invoke-static {v0, p1, v1}, Lcom/htc/android/footprints/utils/ExifInterface;->convertRationalLatLonToDecimalString(Ljava/lang/String;Ljava/lang/String;Z)Ljava/lang/String;

    move-result-object p1

    .line 473
    .end local v0           #lon:Ljava/lang/String;
    .local p1, lon:Ljava/lang/String;
    const-string v0, "FootprintUtils"

    new-instance v1, Ljava/lang/StringBuilder;

    invoke-direct {v1}, Ljava/lang/StringBuilder;-><init>()V

    const-string v2, "read picture lat = "

    invoke-virtual {v1, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v1

    invoke-virtual {v1, p0}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object p0

    .end local p0           #lat:Ljava/lang/String;
    invoke-virtual {p0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object p0

    invoke-static {v0, p0}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I

    .line 474
    const-string p0, "FootprintUtils"

    new-instance v0, Ljava/lang/StringBuilder;

    invoke-direct {v0}, Ljava/lang/StringBuilder;-><init>()V

    const-string v1, "read picture lon = "

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    invoke-virtual {v0, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object p1

    .end local p1           #lon:Ljava/lang/String;
    invoke-virtual {p1}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object p1

    invoke-static {p0, p1}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I

    .line 476
    const-wide/16 p0, 0x0

    .line 477
    .local p0, latitude:D
    const-wide/16 v1, 0x0

    .line 478
    .local v1, longitude:D
    new-instance v0, Landroid/location/Location;

    const-string v3, "gps"

    invoke-direct {v0, v3}, Landroid/location/Location;-><init>(Ljava/lang/String;)V

    .line 479
    .local v0, location:Landroid/location/Location;
    invoke-virtual {v0, p0, p1}, Landroid/location/Location;->setLatitude(D)V

    .line 480
    invoke-virtual {v0, v1, v2}, Landroid/location/Location;->setLongitude(D)V

    .line 482
    return-object v0
.end method

.method public static getLocationFromPicture(Ljava/lang/String;)[I
    .locals 9
    .parameter "path"

    .prologue
    const v7, 0x49742400

    const-string v8, "FootprintUtils"

    .line 364
    const/4 v5, 0x2

    new-array v0, v5, [I

    .line 366
    .local v0, coordinate:[I
    const/4 v4, 0x0

    .line 367
    .local v4, mExifData:Ljava/util/HashMap;,"Ljava/util/HashMap<Ljava/lang/String;Ljava/lang/String;>;"
    new-instance v1, Lcom/htc/android/footprints/utils/ExifInterface;

    invoke-direct {v1, p0}, Lcom/htc/android/footprints/utils/ExifInterface;-><init>(Ljava/lang/String;)V

    .line 368
    .local v1, exif:Lcom/htc/android/footprints/utils/ExifInterface;
    invoke-virtual {v1}, Lcom/htc/android/footprints/utils/ExifInterface;->getAttributes()Ljava/util/HashMap;

    move-result-object v4

    .line 369
    const-string v5, "GPSLatitude"

    invoke-virtual {v4, v5}, Ljava/util/HashMap;->get(Ljava/lang/Object;)Ljava/lang/Object;

    move-result-object v2

    check-cast v2, Ljava/lang/String;

    .line 370
    .local v2, lat:Ljava/lang/String;
    const-string v5, "GPSLongitude"

    invoke-virtual {v4, v5}, Ljava/util/HashMap;->get(Ljava/lang/Object;)Ljava/lang/Object;

    move-result-object v3

    check-cast v3, Ljava/lang/String;

    .line 373
    .local v3, lon:Ljava/lang/String;
    const/4 v5, 0x0

    invoke-static {v2}, Lcom/htc/android/footprints/utils/FootprintUtils;->convertRationalLatLonToDecimalString(Ljava/lang/String;)F

    move-result v6

    mul-float/2addr v6, v7

    float-to-int v6, v6

    aput v6, v0, v5

    .line 374
    const/4 v5, 0x1

    invoke-static {v3}, Lcom/htc/android/footprints/utils/FootprintUtils;->convertRationalLatLonToDecimalString(Ljava/lang/String;)F

    move-result v6

    mul-float/2addr v6, v7

    float-to-int v6, v6

    aput v6, v0, v5

    .line 375
    const-string v5, "FootprintUtils"

    new-instance v5, Ljava/lang/StringBuilder;

    invoke-direct {v5}, Ljava/lang/StringBuilder;-><init>()V

    const-string v6, "read picture lat = "

    invoke-virtual {v5, v6}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v5

    invoke-virtual {v5, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v5

    invoke-virtual {v5}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v5

    invoke-static {v8, v5}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I

    .line 376
    const-string v5, "FootprintUtils"

    new-instance v5, Ljava/lang/StringBuilder;

    invoke-direct {v5}, Ljava/lang/StringBuilder;-><init>()V

    const-string v6, "read picture lon = "

    invoke-virtual {v5, v6}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v5

    invoke-virtual {v5, v3}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v5

    invoke-virtual {v5}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v5

    invoke-static {v8, v5}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I

    .line 378
    return-object v0
.end method

.method public static getResetIntent()Landroid/content/Intent;
    .locals 3

    .prologue
    .line 597
    new-instance v0, Landroid/content/Intent;

    invoke-direct {v0}, Landroid/content/Intent;-><init>()V

    .line 598
    .local v0, resetIntent:Landroid/content/Intent;
    const-string v1, "com.htc.android.footprints.ListModeActivity"

    invoke-virtual {v0, v1}, Landroid/content/Intent;->setAction(Ljava/lang/String;)Landroid/content/Intent;

    .line 599
    const/high16 v1, 0x400

    invoke-virtual {v0, v1}, Landroid/content/Intent;->setFlags(I)Landroid/content/Intent;

    .line 600
    const-string v1, "reset"

    const/4 v2, 0x1

    invoke-virtual {v0, v1, v2}, Landroid/content/Intent;->putExtra(Ljava/lang/String;Z)Landroid/content/Intent;

    .line 601
    return-object v0
.end method

.method public static getSizeOfDB(Landroid/content/Context;)I
    .locals 2
    .parameter "context"

    .prologue
    .line 130
    invoke-static {p0}, Lcom/htc/android/footprints/provider/FootprintManager;->getInstance(Landroid/content/Context;)Lcom/htc/android/footprints/provider/FootprintManager;

    move-result-object v0

    const/4 v1, 0x0

    invoke-virtual {v0, v1}, Lcom/htc/android/footprints/provider/FootprintManager;->getFootprintAll(Ljava/lang/String;)Ljava/util/ArrayList;

    move-result-object v0

    invoke-virtual {v0}, Ljava/util/ArrayList;->size()I

    move-result v0

    return v0
.end method

.method public static getTabCategoryIcon(Landroid/content/Context;Ljava/lang/String;)Landroid/graphics/drawable/Drawable;
    .locals 2
    .parameter "context"
    .parameter "categoryName"

    .prologue
    .line 820
    invoke-virtual {p0}, Landroid/content/Context;->getResources()Landroid/content/res/Resources;

    move-result-object v0

    .line 822
    .local v0, r:Landroid/content/res/Resources;
    const-string v1, "favorite"

    invoke-virtual {p1, v1}, Ljava/lang/String;->equalsIgnoreCase(Ljava/lang/String;)Z

    move-result v1

    if-eqz v1, :cond_0

    .line 823
    const v1, 0x7f020085

    invoke-virtual {v0, v1}, Landroid/content/res/Resources;->getDrawable(I)Landroid/graphics/drawable/Drawable;

    move-result-object v1

    .line 833
    :goto_0
    return-object v1

    .line 824
    :cond_0
    const-string v1, "shopping"

    invoke-virtual {p1, v1}, Ljava/lang/String;->equalsIgnoreCase(Ljava/lang/String;)Z

    move-result v1

    if-eqz v1, :cond_1

    .line 825
    const v1, 0x7f02010a

    invoke-virtual {v0, v1}, Landroid/content/res/Resources;->getDrawable(I)Landroid/graphics/drawable/Drawable;

    move-result-object v1

    goto :goto_0

    .line 826
    :cond_1
    const-string v1, "dining"

    invoke-virtual {p1, v1}, Ljava/lang/String;->equalsIgnoreCase(Ljava/lang/String;)Z

    move-result v1

    if-eqz v1, :cond_2

    .line 827
    const v1, 0x7f020106

    invoke-virtual {v0, v1}, Landroid/content/res/Resources;->getDrawable(I)Landroid/graphics/drawable/Drawable;

    move-result-object v1

    goto :goto_0

    .line 828
    :cond_2
    const-string v1, "leisure"

    invoke-virtual {p1, v1}, Ljava/lang/String;->equalsIgnoreCase(Ljava/lang/String;)Z

    move-result v1

    if-eqz v1, :cond_3

    .line 829
    const v1, 0x7f0200ef

    invoke-virtual {v0, v1}, Landroid/content/res/Resources;->getDrawable(I)Landroid/graphics/drawable/Drawable;

    move-result-object v1

    goto :goto_0

    .line 830
    :cond_3
    const-string v1, "other"

    invoke-virtual {p1, v1}, Ljava/lang/String;->equalsIgnoreCase(Ljava/lang/String;)Z

    move-result v1

    if-eqz v1, :cond_4

    .line 831
    const v1, 0x7f0200f7

    invoke-virtual {v0, v1}, Landroid/content/res/Resources;->getDrawable(I)Landroid/graphics/drawable/Drawable;

    move-result-object v1

    goto :goto_0

    .line 833
    :cond_4
    const v1, 0x7f020001

    invoke-virtual {v0, v1}, Landroid/content/res/Resources;->getDrawable(I)Landroid/graphics/drawable/Drawable;

    move-result-object v1

    goto :goto_0
.end method

.method public static getWBPreferences(Landroid/content/Context;)I
    .locals 4
    .parameter "context"

    .prologue
    const/4 v3, 0x0

    .line 270
    const/4 v1, 0x0

    .line 271
    .local v1, tempWB:I
    const-string v2, "Footprints"

    invoke-virtual {p0, v2, v3}, Landroid/content/Context;->getSharedPreferences(Ljava/lang/String;I)Landroid/content/SharedPreferences;

    move-result-object v0

    .line 272
    .local v0, pref:Landroid/content/SharedPreferences;
    const-string v2, "FOOTPRINTS_CAMERA_WB"

    invoke-interface {v0, v2, v3}, Landroid/content/SharedPreferences;->getInt(Ljava/lang/String;I)I

    move-result v1

    .line 273
    if-gez v1, :cond_0

    .line 274
    invoke-static {p0, v3}, Lcom/htc/android/footprints/utils/FootprintUtils;->putWBPreferences(Landroid/content/Context;I)V

    .line 275
    const/4 v1, 0x0

    .line 277
    :cond_0
    return v1
.end method

.method public static importJPG(Landroid/content/Context;Ljava/io/File;Landroid/graphics/Bitmap;Ljava/lang/String;)Z
    .locals 10
    .parameter "context"
    .parameter "jpg_file"
    .parameter "cropImage"
    .parameter "categoryKey"

    .prologue
    const/4 v9, 0x1

    const/4 v8, 0x0

    .line 933
    if-eqz p1, :cond_0

    if-nez p2, :cond_1

    :cond_0
    move v6, v8

    .line 968
    :goto_0
    return v6

    .line 935
    :cond_1
    invoke-static {v9}, Lcom/htc/android/footprints/utils/camera/FootprintImageManager;->hasStorage(Z)Z

    move-result v6

    if-nez v6, :cond_2

    move v6, v8

    .line 936
    goto :goto_0

    .line 939
    :cond_2
    const/4 v5, 0x0

    .line 940
    .local v5, newFile:Ljava/io/File;
    invoke-static {}, Ljava/lang/System;->currentTimeMillis()J

    move-result-wide v6

    invoke-static {v6, v7}, Ljava/lang/String;->valueOf(J)Ljava/lang/String;

    move-result-object v1

    .line 941
    .local v1, current_time:Ljava/lang/String;
    new-instance v6, Ljava/lang/StringBuilder;

    invoke-direct {v6}, Ljava/lang/StringBuilder;-><init>()V

    invoke-virtual {v6, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v6

    const-string v7, ".jpg"

    invoke-virtual {v6, v7}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v6

    invoke-virtual {v6}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v3

    .line 942
    .local v3, image_name:Ljava/lang/String;
    new-instance v6, Ljava/lang/StringBuilder;

    invoke-direct {v6}, Ljava/lang/StringBuilder;-><init>()V

    invoke-static {}, Lcom/htc/android/footprints/utils/camera/FootprintImageManager;->getDirectory()Ljava/lang/String;

    move-result-object v7

    invoke-virtual {v6, v7}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v6

    sget-object v7, Ljava/io/File;->separator:Ljava/lang/String;

    invoke-virtual {v6, v7}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v6

    invoke-virtual {v6, v3}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v6

    invoke-virtual {v6}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v4

    .line 946
    .local v4, image_name_path:Ljava/lang/String;
    invoke-static {}, Lcom/htc/android/footprints/utils/camera/FootprintImageManager;->getInstance()Lcom/htc/android/footprints/utils/camera/FootprintImageManager;

    move-result-object v6

    invoke-virtual {p0}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;

    move-result-object v7

    invoke-virtual {v6, v7, p2, v3}, Lcom/htc/android/footprints/utils/camera/FootprintImageManager;->forceWriteToFile(Landroid/content/ContentResolver;Landroid/graphics/Bitmap;Ljava/lang/String;)Z

    .line 948
    new-instance v5, Ljava/io/File;

    .end local v5           #newFile:Ljava/io/File;
    invoke-direct {v5, v4}, Ljava/io/File;-><init>(Ljava/lang/String;)V

    .line 949
    .restart local v5       #newFile:Ljava/io/File;
    invoke-virtual {p1}, Ljava/io/File;->getAbsolutePath()Ljava/lang/String;

    move-result-object v6

    invoke-static {v6}, Lcom/htc/android/footprints/utils/FootprintUtils;->getLocationFromPicture(Ljava/lang/String;)[I

    move-result-object v0

    .line 954
    .local v0, coord:[I
    new-instance v2, Lcom/htc/android/footprints/vo/Footprint;

    invoke-direct {v2}, Lcom/htc/android/footprints/vo/Footprint;-><init>()V

    .line 955
    .local v2, footprint:Lcom/htc/android/footprints/vo/Footprint;
    iput-object v1, v2, Lcom/htc/android/footprints/vo/Footprint;->mName:Ljava/lang/String;

    .line 956
    invoke-static {v1}, Ljava/lang/Long;->valueOf(Ljava/lang/String;)Ljava/lang/Long;

    move-result-object v6

    invoke-virtual {v6}, Ljava/lang/Long;->longValue()J

    move-result-wide v6

    iput-wide v6, v2, Lcom/htc/android/footprints/vo/Footprint;->mCreateTime:J

    .line 957
    iput-object v3, v2, Lcom/htc/android/footprints/vo/Footprint;->mPicFileName:Ljava/lang/String;

    .line 958
    iput-object v4, v2, Lcom/htc/android/footprints/vo/Footprint;->mPicPath:Ljava/lang/String;

    .line 959
    if-eqz p3, :cond_3

    invoke-virtual {p3}, Ljava/lang/String;->length()I

    move-result v6

    if-lez v6, :cond_3

    move-object v6, p3

    :goto_1
    iput-object v6, v2, Lcom/htc/android/footprints/vo/Footprint;->mCategory:Ljava/lang/String;

    .line 960
    aget v6, v0, v8

    iput v6, v2, Lcom/htc/android/footprints/vo/Footprint;->mLatitude:I

    .line 961
    aget v6, v0, v9

    iput v6, v2, Lcom/htc/android/footprints/vo/Footprint;->mLongitude:I

    .line 962
    const/4 v6, 0x0

    invoke-virtual {v2, v6}, Lcom/htc/android/footprints/vo/Footprint;->setAudio(Ljava/lang/String;)V

    .line 963
    invoke-static {p0}, Lcom/htc/android/footprints/provider/FootprintManager;->getInstance(Landroid/content/Context;)Lcom/htc/android/footprints/provider/FootprintManager;

    move-result-object v6

    invoke-virtual {v6, v2}, Lcom/htc/android/footprints/provider/FootprintManager;->addFootprint(Lcom/htc/android/footprints/vo/Footprint;)I

    .line 965
    invoke-static {v2}, Lcom/htc/android/footprints/utils/FootprintUtils;->setLocationToPicture(Lcom/htc/android/footprints/vo/Footprint;)V

    .line 967
    const/4 p2, 0x0

    move v6, v9

    .line 968
    goto/16 :goto_0

    .line 959
    :cond_3
    const-string v6, "favorite"

    goto :goto_1
.end method

.method public static isOnBackground(Landroid/content/Context;)Z
    .locals 12
    .parameter "context"

    .prologue
    const-string v11, " / "

    const-string v10, "FootprintUtils"

    .line 1089
    const/4 v7, 0x0

    .line 1090
    .local v7, result:Z
    const-string v8, "activity"

    invoke-virtual {p0, v8}, Landroid/content/Context;->getSystemService(Ljava/lang/String;)Ljava/lang/Object;

    move-result-object v0

    check-cast v0, Landroid/app/ActivityManager;

    .line 1093
    .local v0, am:Landroid/app/ActivityManager;
    invoke-virtual {v0}, Landroid/app/ActivityManager;->getRunningAppProcesses()Ljava/util/List;

    move-result-object v6

    .line 1094
    .local v6, rapi:Ljava/util/List;,"Ljava/util/List<Landroid/app/ActivityManager$RunningAppProcessInfo;>;"
    const-string v1, "com.htc.android.footprints"

    .line 1096
    .local v1, app:Ljava/lang/String;
    invoke-interface {v6}, Ljava/util/List;->iterator()Ljava/util/Iterator;

    move-result-object v2

    .local v2, i$:Ljava/util/Iterator;
    :cond_0
    invoke-interface {v2}, Ljava/util/Iterator;->hasNext()Z

    move-result v8

    if-eqz v8, :cond_1

    invoke-interface {v2}, Ljava/util/Iterator;->next()Ljava/lang/Object;

    move-result-object v5

    check-cast v5, Landroid/app/ActivityManager$RunningAppProcessInfo;

    .line 1097
    .local v5, r:Landroid/app/ActivityManager$RunningAppProcessInfo;
    iget-object v4, v5, Landroid/app/ActivityManager$RunningAppProcessInfo;->processName:Ljava/lang/String;

    .line 1098
    .local v4, name:Ljava/lang/String;
    iget v3, v5, Landroid/app/ActivityManager$RunningAppProcessInfo;->importance:I

    .line 1100
    .local v3, im:I
    const-string v8, "FootprintUtils"

    new-instance v8, Ljava/lang/StringBuilder;

    invoke-direct {v8}, Ljava/lang/StringBuilder;-><init>()V

    const-string v9, "name/importance/lru = "

    invoke-virtual {v8, v9}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v8

    invoke-virtual {v8, v4}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v8

    const-string v9, " / "

    invoke-virtual {v8, v11}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v8

    invoke-virtual {v8, v3}, Ljava/lang/StringBuilder;->append(I)Ljava/lang/StringBuilder;

    move-result-object v8

    const-string v9, " / "

    invoke-virtual {v8, v11}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v8

    iget v9, v5, Landroid/app/ActivityManager$RunningAppProcessInfo;->lru:I

    invoke-virtual {v8, v9}, Ljava/lang/StringBuilder;->append(I)Ljava/lang/StringBuilder;

    move-result-object v8

    invoke-virtual {v8}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v8

    invoke-static {v10, v8}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I

    .line 1103
    invoke-virtual {v4, v1}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v8

    if-eqz v8, :cond_0

    .line 1104
    const-string v8, "FootprintUtils"

    const-string v8, "app = footprint"

    invoke-static {v10, v8}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I

    .line 1105
    const-string v8, "FootprintUtils"

    new-instance v8, Ljava/lang/StringBuilder;

    invoke-direct {v8}, Ljava/lang/StringBuilder;-><init>()V

    const-string v9, "app name / importance = "

    invoke-virtual {v8, v9}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v8

    invoke-virtual {v8, v4}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v8

    const-string v9, " / "

    invoke-virtual {v8, v11}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v8

    invoke-virtual {v8, v3}, Ljava/lang/StringBuilder;->append(I)Ljava/lang/StringBuilder;

    move-result-object v8

    invoke-virtual {v8}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v8

    invoke-static {v10, v8}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I

    .line 1107
    const/16 v8, 0x190

    if-ne v8, v3, :cond_0

    .line 1108
    const/4 v7, 0x1

    .line 1109
    const-string v8, "FootprintUtils"

    new-instance v8, Ljava/lang/StringBuilder;

    invoke-direct {v8}, Ljava/lang/StringBuilder;-><init>()V

    invoke-virtual {v8, v4}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v8

    const-string v9, ": background"

    invoke-virtual {v8, v9}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v8

    const-string v9, ", "

    invoke-virtual {v8, v9}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v8

    iget v9, v5, Landroid/app/ActivityManager$RunningAppProcessInfo;->lru:I

    invoke-virtual {v8, v9}, Ljava/lang/StringBuilder;->append(I)Ljava/lang/StringBuilder;

    move-result-object v8

    invoke-virtual {v8}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v8

    invoke-static {v10, v8}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I

    .line 1126
    .end local v3           #im:I
    .end local v4           #name:Ljava/lang/String;
    .end local v5           #r:Landroid/app/ActivityManager$RunningAppProcessInfo;
    :cond_1
    return v7
.end method

.method public static isResetByWidget()Z
    .locals 8

    .prologue
    .line 1157
    invoke-static {}, Lcom/htc/android/footprints/utils/camera/FootprintImageManager;->getFootprintsDirectory()Ljava/lang/String;

    move-result-object v2

    .line 1159
    .local v2, sdPath:Ljava/lang/String;
    new-instance v4, Ljava/lang/StringBuilder;

    invoke-direct {v4}, Ljava/lang/StringBuilder;-><init>()V

    invoke-virtual {v4, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v4

    sget-object v5, Ljava/io/File;->separator:Ljava/lang/String;

    invoke-virtual {v4, v5}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v4

    const-string v5, "fpwidget.txt"

    invoke-virtual {v4, v5}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v4

    invoke-virtual {v4}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v0

    .line 1161
    .local v0, path:Ljava/lang/String;
    new-instance v3, Ljava/io/File;

    invoke-direct {v3, v0}, Ljava/io/File;-><init>(Ljava/lang/String;)V

    .line 1162
    .local v3, widgetFile:Ljava/io/File;
    invoke-virtual {v3}, Ljava/io/File;->exists()Z

    move-result v1

    .line 1163
    .local v1, result:Z
    if-eqz v1, :cond_0

    .line 1164
    new-instance v4, Landroid/os/Handler;

    invoke-direct {v4}, Landroid/os/Handler;-><init>()V

    new-instance v5, Lcom/htc/android/footprints/utils/FootprintUtils$5;

    invoke-direct {v5, v3}, Lcom/htc/android/footprints/utils/FootprintUtils$5;-><init>(Ljava/io/File;)V

    const-wide/16 v6, 0x1f4

    invoke-virtual {v4, v5, v6, v7}, Landroid/os/Handler;->postDelayed(Ljava/lang/Runnable;J)Z

    .line 1171
    :cond_0
    const-string v4, "FootprintUtils"

    new-instance v5, Ljava/lang/StringBuilder;

    invoke-direct {v5}, Ljava/lang/StringBuilder;-><init>()V

    const-string v6, "isResetByWidget = "

    invoke-virtual {v5, v6}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v5

    invoke-virtual {v5, v1}, Ljava/lang/StringBuilder;->append(Z)Ljava/lang/StringBuilder;

    move-result-object v5

    invoke-virtual {v5}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v5

    invoke-static {v4, v5}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I

    .line 1172
    return v1
.end method

.method public static isStorageEnough(Landroid/content/Context;)Z
    .locals 4
    .parameter "context"

    .prologue
    .line 907
    invoke-static {}, Lcom/htc/android/footprints/utils/StorageUtil;->isExternalStorageEnough()Z

    move-result v2

    if-eqz v2, :cond_0

    invoke-static {}, Lcom/htc/android/footprints/utils/StorageUtil;->isInternalStorageEnough()Z

    move-result v2

    if-eqz v2, :cond_0

    .line 908
    const/4 v1, 0x1

    .line 918
    .local v1, isEnough:Z
    :goto_0
    return v1

    .line 910
    .end local v1           #isEnough:Z
    :cond_0
    move-object v0, p0

    check-cast v0, Landroid/app/Activity;

    move-object v2, v0

    new-instance v3, Lcom/htc/android/footprints/utils/FootprintUtils$4;

    invoke-direct {v3, p0}, Lcom/htc/android/footprints/utils/FootprintUtils$4;-><init>(Landroid/content/Context;)V

    invoke-virtual {v2, v3}, Landroid/app/Activity;->runOnUiThread(Ljava/lang/Runnable;)V

    .line 916
    const/4 v1, 0x0

    .restart local v1       #isEnough:Z
    goto :goto_0
.end method

.method public static isStorageEnough(Landroid/content/Context;J)Z
    .locals 4
    .parameter "context"
    .parameter "needSpace"

    .prologue
    .line 889
    const-wide/32 v2, 0x200000

    add-long/2addr v2, p1

    invoke-static {v2, v3}, Lcom/htc/android/footprints/utils/StorageUtil;->isExternalStorageEnough(J)Z

    move-result v2

    if-eqz v2, :cond_0

    .line 891
    const/4 v1, 0x1

    .line 902
    .local v1, isEnough:Z
    :goto_0
    return v1

    .line 893
    .end local v1           #isEnough:Z
    :cond_0
    move-object v0, p0

    check-cast v0, Landroid/app/Activity;

    move-object v2, v0

    new-instance v3, Lcom/htc/android/footprints/utils/FootprintUtils$3;

    invoke-direct {v3, p0}, Lcom/htc/android/footprints/utils/FootprintUtils$3;-><init>(Landroid/content/Context;)V

    invoke-virtual {v2, v3}, Landroid/app/Activity;->runOnUiThread(Ljava/lang/Runnable;)V

    .line 900
    const/4 v1, 0x0

    .restart local v1       #isEnough:Z
    goto :goto_0
.end method

.method public static processPreset(Landroid/content/Context;)V
    .locals 12
    .parameter "context"

    .prologue
    const/4 v9, 0x0

    const-string v11, "PRESET"

    const-string v10, "FootprintUtils"

    .line 996
    const-string v5, "PRESET"

    .line 997
    .local v5, keywork:Ljava/lang/String;
    const-string v8, "Footprints"

    invoke-virtual {p0, v8, v9}, Landroid/content/Context;->getSharedPreferences(Ljava/lang/String;I)Landroid/content/SharedPreferences;

    move-result-object v6

    .line 998
    .local v6, pref:Landroid/content/SharedPreferences;
    const-string v8, "PRESET"

    invoke-interface {v6, v11, v9}, Landroid/content/SharedPreferences;->getBoolean(Ljava/lang/String;Z)Z

    move-result v3

    .line 999
    .local v3, hasPreset:Z
    invoke-static {p0}, Lcom/htc/android/footprints/provider/FootprintManager;->getInstance(Landroid/content/Context;)Lcom/htc/android/footprints/provider/FootprintManager;

    move-result-object v2

    .line 1000
    .local v2, ftManager:Lcom/htc/android/footprints/provider/FootprintManager;
    if-nez v3, :cond_0

    .line 1001
    invoke-interface {v6}, Landroid/content/SharedPreferences;->edit()Landroid/content/SharedPreferences$Editor;

    move-result-object v1

    .line 1002
    .local v1, editor:Landroid/content/SharedPreferences$Editor;
    const-string v8, "PRESET"

    const/4 v8, 0x1

    invoke-interface {v1, v11, v8}, Landroid/content/SharedPreferences$Editor;->putBoolean(Ljava/lang/String;Z)Landroid/content/SharedPreferences$Editor;

    .line 1003
    invoke-interface {v1}, Landroid/content/SharedPreferences$Editor;->commit()Z

    .line 1005
    const-string v8, "FootprintUtils"

    const-string v8, "install preset Footprints"

    invoke-static {v10, v8}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I

    .line 1006
    invoke-static {}, Lcom/htc/android/footprints/utils/FootprintUtils;->touchSDFile()V

    .line 1007
    const/4 v4, 0x0

    .line 1009
    .local v4, input:Ljava/io/InputStream;
    :try_start_0
    invoke-virtual {p0}, Landroid/content/Context;->getAssets()Landroid/content/res/AssetManager;

    move-result-object v8

    const-string v9, "preset.kmz"

    invoke-virtual {v8, v9}, Landroid/content/res/AssetManager;->open(Ljava/lang/String;)Ljava/io/InputStream;

    move-result-object v4

    .line 1010
    invoke-static {v4}, Lcom/htc/android/footprints/kml/KMLUtil;->importKMZ(Ljava/io/InputStream;)[Lcom/htc/android/footprints/vo/Footprint;

    move-result-object v7

    .line 1011
    .local v7, presetFootprint:[Lcom/htc/android/footprints/vo/Footprint;
    invoke-virtual {v2, v7}, Lcom/htc/android/footprints/provider/FootprintManager;->addNonDuplicatedFootprint([Lcom/htc/android/footprints/vo/Footprint;)V
    :try_end_0
    .catchall {:try_start_0 .. :try_end_0} :catchall_0
    .catch Ljava/io/IOException; {:try_start_0 .. :try_end_0} :catch_1

    .line 1015
    if-eqz v4, :cond_0

    .line 1017
    :try_start_1
    invoke-virtual {v4}, Ljava/io/InputStream;->close()V
    :try_end_1
    .catch Ljava/io/IOException; {:try_start_1 .. :try_end_1} :catch_0

    .line 1028
    .end local v1           #editor:Landroid/content/SharedPreferences$Editor;
    .end local v4           #input:Ljava/io/InputStream;
    .end local v7           #presetFootprint:[Lcom/htc/android/footprints/vo/Footprint;
    :cond_0
    :goto_0
    return-void

    .line 1018
    .restart local v1       #editor:Landroid/content/SharedPreferences$Editor;
    .restart local v4       #input:Ljava/io/InputStream;
    .restart local v7       #presetFootprint:[Lcom/htc/android/footprints/vo/Footprint;
    :catch_0
    move-exception v0

    .line 1019
    .local v0, e:Ljava/io/IOException;
    const-string v8, "FootprintUtils"

    invoke-virtual {v0}, Ljava/io/IOException;->getMessage()Ljava/lang/String;

    move-result-object v8

    invoke-static {v10, v8, v0}, Landroid/util/Log;->w(Ljava/lang/String;Ljava/lang/String;Ljava/lang/Throwable;)I

    goto :goto_0

    .line 1012
    .end local v0           #e:Ljava/io/IOException;
    .end local v7           #presetFootprint:[Lcom/htc/android/footprints/vo/Footprint;
    :catch_1
    move-exception v8

    move-object v0, v8

    .line 1013
    .restart local v0       #e:Ljava/io/IOException;
    :try_start_2
    const-string v8, "FootprintUtils"

    invoke-virtual {v0}, Ljava/io/IOException;->getMessage()Ljava/lang/String;

    move-result-object v9

    invoke-static {v8, v9, v0}, Landroid/util/Log;->e(Ljava/lang/String;Ljava/lang/String;Ljava/lang/Throwable;)I
    :try_end_2
    .catchall {:try_start_2 .. :try_end_2} :catchall_0

    .line 1015
    if-eqz v4, :cond_0

    .line 1017
    :try_start_3
    invoke-virtual {v4}, Ljava/io/InputStream;->close()V
    :try_end_3
    .catch Ljava/io/IOException; {:try_start_3 .. :try_end_3} :catch_2

    goto :goto_0

    .line 1018
    :catch_2
    move-exception v0

    .line 1019
    const-string v8, "FootprintUtils"

    invoke-virtual {v0}, Ljava/io/IOException;->getMessage()Ljava/lang/String;

    move-result-object v8

    invoke-static {v10, v8, v0}, Landroid/util/Log;->w(Ljava/lang/String;Ljava/lang/String;Ljava/lang/Throwable;)I

    goto :goto_0

    .line 1015
    .end local v0           #e:Ljava/io/IOException;
    :catchall_0
    move-exception v8

    if-eqz v4, :cond_1

    .line 1017
    :try_start_4
    invoke-virtual {v4}, Ljava/io/InputStream;->close()V
    :try_end_4
    .catch Ljava/io/IOException; {:try_start_4 .. :try_end_4} :catch_3

    .line 1020
    :cond_1
    :goto_1
    throw v8

    .line 1018
    :catch_3
    move-exception v0

    .line 1019
    .restart local v0       #e:Ljava/io/IOException;
    const-string v9, "FootprintUtils"

    invoke-virtual {v0}, Ljava/io/IOException;->getMessage()Ljava/lang/String;

    move-result-object v9

    invoke-static {v10, v9, v0}, Landroid/util/Log;->w(Ljava/lang/String;Ljava/lang/String;Ljava/lang/Throwable;)I

    goto :goto_1
.end method

.method public static processPresetDate(Landroid/content/Context;)V
    .locals 7
    .parameter "context"

    .prologue
    .line 1031
    const-string v0, "FootprintUtils"

    const-string v1, "preset data"

    invoke-static {v0, v1}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I

    .line 1032
    const-string v0, "PRESET"

    .line 1033
    .local v0, keywork:Ljava/lang/String;
    invoke-static {}, Lcom/htc/android/footprints/utils/FootprintUtils;->touchSDFile()V

    .line 1035
    const-string v0, "Footprints"

    .end local v0           #keywork:Ljava/lang/String;
    const/4 v1, 0x0

    invoke-virtual {p0, v0, v1}, Landroid/content/Context;->getSharedPreferences(Ljava/lang/String;I)Landroid/content/SharedPreferences;

    move-result-object v4

    .line 1036
    .local v4, pref:Landroid/content/SharedPreferences;
    const-string v0, "PRESET"

    const/4 v1, 0x0

    invoke-interface {v4, v0, v1}, Landroid/content/SharedPreferences;->getBoolean(Ljava/lang/String;Z)Z

    move-result v3

    .line 1038
    .local v3, hasPreset:Z
    invoke-static {p0}, Lcom/htc/android/footprints/provider/FootprintManager;->getInstance(Landroid/content/Context;)Lcom/htc/android/footprints/provider/FootprintManager;

    move-result-object v2

    .line 1041
    .local v2, ftManager:Lcom/htc/android/footprints/provider/FootprintManager;
    new-instance v0, Ljava/io/File;

    new-instance v1, Ljava/lang/StringBuilder;

    invoke-direct {v1}, Ljava/lang/StringBuilder;-><init>()V

    invoke-static {}, Lcom/htc/android/footprints/utils/StorageUtil;->getFootprintStorageDirectory()Ljava/lang/String;

    move-result-object v5

    invoke-virtual {v1, v5}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v1

    sget-object v5, Ljava/io/File;->separator:Ljava/lang/String;

    invoke-virtual {v1, v5}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v1

    const-string v5, "footprints.db"

    invoke-virtual {v1, v5}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v1

    invoke-virtual {v1}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v1

    invoke-direct {v0, v1}, Ljava/io/File;-><init>(Ljava/lang/String;)V

    .line 1043
    .local v0, f:Ljava/io/File;
    invoke-virtual {v0}, Ljava/io/File;->exists()Z

    move-result v1

    if-eqz v1, :cond_0

    .line 1044
    const-string v1, "footprints.db"

    invoke-virtual {p0, v1}, Landroid/content/Context;->getDatabasePath(Ljava/lang/String;)Ljava/io/File;

    move-result-object v1

    .line 1053
    .local v1, ftDB:Ljava/io/File;
    invoke-static {v0, v1}, Lcom/htc/android/footprints/utils/FootprintUtils;->copyFile(Ljava/io/File;Ljava/io/File;)Z

    move-result v0

    .line 1054
    .local v0, isSuccess:Z
    if-eqz v0, :cond_0

    .line 1055
    invoke-interface {v4}, Landroid/content/SharedPreferences;->edit()Landroid/content/SharedPreferences$Editor;

    move-result-object v0

    .line 1056
    .local v0, editor:Landroid/content/SharedPreferences$Editor;
    const-string v1, "PRESET"

    .end local v1           #ftDB:Ljava/io/File;
    const/4 v5, 0x1

    invoke-interface {v0, v1, v5}, Landroid/content/SharedPreferences$Editor;->putBoolean(Ljava/lang/String;Z)Landroid/content/SharedPreferences$Editor;

    .line 1057
    invoke-interface {v0}, Landroid/content/SharedPreferences$Editor;->commit()Z

    .line 1063
    .end local v0           #editor:Landroid/content/SharedPreferences$Editor;
    :cond_0
    if-nez v3, :cond_1

    .line 1064
    const-string v0, "FootprintUtils"

    const-string v1, "install preset Footprints"

    invoke-static {v0, v1}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I

    .line 1065
    const/4 v0, 0x0

    .line 1067
    .local v0, input:Ljava/io/InputStream;
    :try_start_0
    invoke-virtual {p0}, Landroid/content/Context;->getAssets()Landroid/content/res/AssetManager;

    move-result-object p0

    .end local p0
    const-string v1, "preset.kmz"

    invoke-virtual {p0, v1}, Landroid/content/res/AssetManager;->open(Ljava/lang/String;)Ljava/io/InputStream;

    move-result-object v0

    .line 1068
    invoke-static {v0}, Lcom/htc/android/footprints/kml/KMLUtil;->importKMZ(Ljava/io/InputStream;)[Lcom/htc/android/footprints/vo/Footprint;

    move-result-object p0

    .line 1069
    .local p0, presetFootprint:[Lcom/htc/android/footprints/vo/Footprint;
    invoke-virtual {v2, p0}, Lcom/htc/android/footprints/provider/FootprintManager;->addFootprint([Lcom/htc/android/footprints/vo/Footprint;)V
    :try_end_0
    .catchall {:try_start_0 .. :try_end_0} :catchall_0
    .catch Ljava/io/IOException; {:try_start_0 .. :try_end_0} :catch_1

    .line 1073
    if-eqz v0, :cond_3

    .line 1075
    :try_start_1
    invoke-virtual {v0}, Ljava/io/InputStream;->close()V
    :try_end_1
    .catch Ljava/io/IOException; {:try_start_1 .. :try_end_1} :catch_0

    move-object p0, v0

    .line 1082
    .end local v0           #input:Ljava/io/InputStream;
    .end local v2           #ftManager:Lcom/htc/android/footprints/provider/FootprintManager;
    .local p0, input:Ljava/io/InputStream;
    :goto_0
    invoke-interface {v4}, Landroid/content/SharedPreferences;->edit()Landroid/content/SharedPreferences$Editor;

    move-result-object p0

    .line 1083
    .local p0, editor:Landroid/content/SharedPreferences$Editor;
    const-string v0, "PRESET"

    const/4 v1, 0x1

    invoke-interface {p0, v0, v1}, Landroid/content/SharedPreferences$Editor;->putBoolean(Ljava/lang/String;Z)Landroid/content/SharedPreferences$Editor;

    .line 1084
    invoke-interface {p0}, Landroid/content/SharedPreferences$Editor;->commit()Z

    .line 1086
    .end local p0           #editor:Landroid/content/SharedPreferences$Editor;
    :cond_1
    return-void

    .line 1076
    .restart local v0       #input:Ljava/io/InputStream;
    .restart local v2       #ftManager:Lcom/htc/android/footprints/provider/FootprintManager;
    .local p0, presetFootprint:[Lcom/htc/android/footprints/vo/Footprint;
    :catch_0
    move-exception p0

    .line 1077
    .local p0, e:Ljava/io/IOException;
    const-string v1, "FootprintUtils"

    invoke-virtual {p0}, Ljava/io/IOException;->getMessage()Ljava/lang/String;

    move-result-object v2

    .end local v2           #ftManager:Lcom/htc/android/footprints/provider/FootprintManager;
    invoke-static {v1, v2, p0}, Landroid/util/Log;->w(Ljava/lang/String;Ljava/lang/String;Ljava/lang/Throwable;)I

    move-object p0, v0

    .line 1078
    .end local v0           #input:Ljava/io/InputStream;
    .local p0, input:Ljava/io/InputStream;
    goto :goto_0

    .line 1070
    .end local p0           #input:Ljava/io/InputStream;
    .restart local v0       #input:Ljava/io/InputStream;
    .restart local v2       #ftManager:Lcom/htc/android/footprints/provider/FootprintManager;
    :catch_1
    move-exception p0

    .line 1071
    .local p0, e:Ljava/io/IOException;
    :try_start_2
    const-string v1, "FootprintUtils"

    invoke-virtual {p0}, Ljava/io/IOException;->getMessage()Ljava/lang/String;

    move-result-object v2

    .end local v2           #ftManager:Lcom/htc/android/footprints/provider/FootprintManager;
    invoke-static {v1, v2, p0}, Landroid/util/Log;->e(Ljava/lang/String;Ljava/lang/String;Ljava/lang/Throwable;)I
    :try_end_2
    .catchall {:try_start_2 .. :try_end_2} :catchall_0

    .line 1073
    if-eqz v0, :cond_3

    .line 1075
    :try_start_3
    invoke-virtual {v0}, Ljava/io/InputStream;->close()V
    :try_end_3
    .catch Ljava/io/IOException; {:try_start_3 .. :try_end_3} :catch_2

    move-object p0, v0

    .line 1078
    .end local v0           #input:Ljava/io/InputStream;
    .local p0, input:Ljava/io/InputStream;
    goto :goto_0

    .line 1076
    .restart local v0       #input:Ljava/io/InputStream;
    .local p0, e:Ljava/io/IOException;
    :catch_2
    move-exception p0

    .line 1077
    const-string v1, "FootprintUtils"

    invoke-virtual {p0}, Ljava/io/IOException;->getMessage()Ljava/lang/String;

    move-result-object v2

    invoke-static {v1, v2, p0}, Landroid/util/Log;->w(Ljava/lang/String;Ljava/lang/String;Ljava/lang/Throwable;)I

    move-object p0, v0

    .line 1078
    .end local v0           #input:Ljava/io/InputStream;
    .local p0, input:Ljava/io/InputStream;
    goto :goto_0

    .line 1073
    .end local p0           #input:Ljava/io/InputStream;
    .restart local v0       #input:Ljava/io/InputStream;
    :catchall_0
    move-exception p0

    move-object v6, p0

    move-object p0, v0

    .end local v0           #input:Ljava/io/InputStream;
    .restart local p0       #input:Ljava/io/InputStream;
    move-object v0, v6

    if-eqz p0, :cond_2

    .line 1075
    :try_start_4
    invoke-virtual {p0}, Ljava/io/InputStream;->close()V
    :try_end_4
    .catch Ljava/io/IOException; {:try_start_4 .. :try_end_4} :catch_3

    .line 1078
    .end local p0           #input:Ljava/io/InputStream;
    :cond_2
    :goto_1
    throw v0

    .line 1076
    .restart local p0       #input:Ljava/io/InputStream;
    :catch_3
    move-exception p0

    .line 1077
    .local p0, e:Ljava/io/IOException;
    const-string v1, "FootprintUtils"

    invoke-virtual {p0}, Ljava/io/IOException;->getMessage()Ljava/lang/String;

    move-result-object v2

    invoke-static {v1, v2, p0}, Landroid/util/Log;->w(Ljava/lang/String;Ljava/lang/String;Ljava/lang/Throwable;)I

    goto :goto_1

    .end local p0           #e:Ljava/io/IOException;
    .restart local v0       #input:Ljava/io/InputStream;
    :cond_3
    move-object p0, v0

    .end local v0           #input:Ljava/io/InputStream;
    .local p0, input:Ljava/io/InputStream;
    goto :goto_0
.end method

.method public static putBrightPreferences(Landroid/content/Context;I)V
    .locals 4
    .parameter "context"
    .parameter "brightness"

    .prologue
    .line 281
    const-string v2, "Footprints"

    const/4 v3, 0x0

    invoke-virtual {p0, v2, v3}, Landroid/content/Context;->getSharedPreferences(Ljava/lang/String;I)Landroid/content/SharedPreferences;

    move-result-object v1

    .line 282
    .local v1, pref:Landroid/content/SharedPreferences;
    invoke-interface {v1}, Landroid/content/SharedPreferences;->edit()Landroid/content/SharedPreferences$Editor;

    move-result-object v0

    .line 283
    .local v0, editor:Landroid/content/SharedPreferences$Editor;
    const-string v2, "FOOTPRINTS_CAMERA_BRIGHT"

    invoke-interface {v0, v2, p1}, Landroid/content/SharedPreferences$Editor;->putInt(Ljava/lang/String;I)Landroid/content/SharedPreferences$Editor;

    .line 284
    invoke-interface {v0}, Landroid/content/SharedPreferences$Editor;->commit()Z

    .line 285
    return-void
.end method

.method public static putWBPreferences(Landroid/content/Context;I)V
    .locals 4
    .parameter "context"
    .parameter "wb"

    .prologue
    .line 263
    const-string v2, "Footprints"

    const/4 v3, 0x0

    invoke-virtual {p0, v2, v3}, Landroid/content/Context;->getSharedPreferences(Ljava/lang/String;I)Landroid/content/SharedPreferences;

    move-result-object v1

    .line 264
    .local v1, pref:Landroid/content/SharedPreferences;
    invoke-interface {v1}, Landroid/content/SharedPreferences;->edit()Landroid/content/SharedPreferences$Editor;

    move-result-object v0

    .line 265
    .local v0, editor:Landroid/content/SharedPreferences$Editor;
    const-string v2, "FOOTPRINTS_CAMERA_WB"

    invoke-interface {v0, v2, p1}, Landroid/content/SharedPreferences$Editor;->putInt(Ljava/lang/String;I)Landroid/content/SharedPreferences$Editor;

    .line 266
    invoke-interface {v0}, Landroid/content/SharedPreferences$Editor;->commit()Z

    .line 267
    return-void
.end method

.method private static replaceExifTag(Ljava/util/HashMap;Ljava/lang/String;Ljava/lang/String;)V
    .locals 1
    .parameter
    .parameter "tag"
    .parameter "value"
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "(",
            "Ljava/util/HashMap",
            "<",
            "Ljava/lang/String;",
            "Ljava/lang/String;",
            ">;",
            "Ljava/lang/String;",
            "Ljava/lang/String;",
            ")V"
        }
    .end annotation

    .prologue
    .line 571
    .local p0, exifData:Ljava/util/HashMap;,"Ljava/util/HashMap<Ljava/lang/String;Ljava/lang/String;>;"
    if-nez p0, :cond_0

    .line 578
    :goto_0
    return-void

    .line 574
    :cond_0
    invoke-virtual {p0, p1}, Ljava/util/HashMap;->containsKey(Ljava/lang/Object;)Z

    move-result v0

    if-nez v0, :cond_1

    .line 575
    invoke-virtual {p0, p1}, Ljava/util/HashMap;->remove(Ljava/lang/Object;)Ljava/lang/Object;

    .line 577
    :cond_1
    invoke-virtual {p0, p1, p2}, Ljava/util/HashMap;->put(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;

    goto :goto_0
.end method

.method public static saveAsContacts(Landroid/content/Context;Lcom/htc/android/footprints/vo/Footprint;)V
    .locals 9
    .parameter "context"
    .parameter "footprint"

    .prologue
    const/16 v3, 0x32

    const-string v8, ""

    .line 1232
    new-instance v7, Landroid/content/Intent;

    invoke-direct {v7}, Landroid/content/Intent;-><init>()V

    .line 1233
    .local v7, intent:Landroid/content/Intent;
    const/high16 v0, 0x1000

    invoke-virtual {v7, v0}, Landroid/content/Intent;->addFlags(I)Landroid/content/Intent;

    .line 1234
    const-string v0, "android.intent.action.INSERT"

    invoke-virtual {v7, v0}, Landroid/content/Intent;->setAction(Ljava/lang/String;)Landroid/content/Intent;

    .line 1235
    const-string v0, "content://contacts/people"

    invoke-static {v0}, Landroid/net/Uri;->parse(Ljava/lang/String;)Landroid/net/Uri;

    move-result-object v0

    invoke-virtual {v7, v0}, Landroid/content/Intent;->setData(Landroid/net/Uri;)Landroid/content/Intent;

    .line 1236
    invoke-static {}, Lcom/htc/android/footprints/utils/camera/FootprintImageManager;->getInstance()Lcom/htc/android/footprints/utils/camera/FootprintImageManager;

    move-result-object v0

    new-instance v1, Ljava/io/File;

    iget-object v2, p1, Lcom/htc/android/footprints/vo/Footprint;->mPicPath:Ljava/lang/String;

    invoke-direct {v1, v2}, Ljava/io/File;-><init>(Ljava/lang/String;)V

    const/4 v5, 0x0

    move-object v2, p0

    move v4, v3

    invoke-virtual/range {v0 .. v5}, Lcom/htc/android/footprints/utils/camera/FootprintImageManager;->getScaledImage(Ljava/io/File;Landroid/content/Context;IIZ)Landroid/graphics/Bitmap;

    move-result-object v6

    .line 1237
    .local v6, bitmap:Landroid/graphics/Bitmap;
    const-string v0, "ConImage"

    invoke-virtual {v7, v0, v6}, Landroid/content/Intent;->putExtra(Ljava/lang/String;Landroid/os/Parcelable;)Landroid/content/Intent;

    .line 1238
    const-string v0, "name"

    iget-object v1, p1, Lcom/htc/android/footprints/vo/Footprint;->mName:Ljava/lang/String;

    invoke-virtual {v7, v0, v1}, Landroid/content/Intent;->putExtra(Ljava/lang/String;Ljava/lang/String;)Landroid/content/Intent;

    .line 1239
    const-string v0, "notes"

    iget-object v1, p1, Lcom/htc/android/footprints/vo/Footprint;->mComment:Ljava/lang/String;

    if-eqz v1, :cond_0

    iget-object v1, p1, Lcom/htc/android/footprints/vo/Footprint;->mComment:Ljava/lang/String;

    invoke-virtual {v1}, Ljava/lang/String;->length()I

    move-result v1

    if-lez v1, :cond_0

    iget-object v1, p1, Lcom/htc/android/footprints/vo/Footprint;->mComment:Ljava/lang/String;

    :goto_0
    invoke-virtual {v7, v0, v1}, Landroid/content/Intent;->putExtra(Ljava/lang/String;Ljava/lang/String;)Landroid/content/Intent;

    .line 1240
    const-string v0, "postal"

    iget-object v1, p1, Lcom/htc/android/footprints/vo/Footprint;->mAddr:Ljava/lang/String;

    if-eqz v1, :cond_1

    iget-object v1, p1, Lcom/htc/android/footprints/vo/Footprint;->mAddr:Ljava/lang/String;

    invoke-virtual {v1}, Ljava/lang/String;->length()I

    move-result v1

    if-lez v1, :cond_1

    iget-object v1, p1, Lcom/htc/android/footprints/vo/Footprint;->mAddr:Ljava/lang/String;

    :goto_1
    invoke-virtual {v7, v0, v1}, Landroid/content/Intent;->putExtra(Ljava/lang/String;Ljava/lang/String;)Landroid/content/Intent;

    .line 1241
    const-string v0, "phone"

    iget-object v1, p1, Lcom/htc/android/footprints/vo/Footprint;->mTel:Ljava/lang/String;

    if-eqz v1, :cond_2

    iget-object v1, p1, Lcom/htc/android/footprints/vo/Footprint;->mTel:Ljava/lang/String;

    invoke-virtual {v1}, Ljava/lang/String;->length()I

    move-result v1

    if-lez v1, :cond_2

    iget-object v1, p1, Lcom/htc/android/footprints/vo/Footprint;->mTel:Ljava/lang/String;

    :goto_2
    invoke-virtual {v7, v0, v1}, Landroid/content/Intent;->putExtra(Ljava/lang/String;Ljava/lang/String;)Landroid/content/Intent;

    .line 1242
    invoke-virtual {p0, v7}, Landroid/content/Context;->startActivity(Landroid/content/Intent;)V

    .line 1243
    const/4 v6, 0x0

    .line 1244
    return-void

    .line 1239
    :cond_0
    const-string v1, ""

    move-object v1, v8

    goto :goto_0

    .line 1240
    :cond_1
    const-string v1, ""

    move-object v1, v8

    goto :goto_1

    .line 1241
    :cond_2
    const-string v1, ""

    move-object v1, v8

    goto :goto_2
.end method

.method public static saveFootprintIndex(I)V
    .locals 8
    .parameter "index"

    .prologue
    .line 1176
    invoke-static {}, Lcom/htc/android/footprints/utils/camera/FootprintImageManager;->getFootprintsDirectory()Ljava/lang/String;

    move-result-object v3

    .line 1178
    .local v3, sdPath:Ljava/lang/String;
    new-instance v5, Ljava/lang/StringBuilder;

    invoke-direct {v5}, Ljava/lang/StringBuilder;-><init>()V

    invoke-virtual {v5, v3}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v5

    sget-object v6, Ljava/io/File;->separator:Ljava/lang/String;

    invoke-virtual {v5, v6}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v5

    const-string v6, "index.txt"

    invoke-virtual {v5, v6}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v5

    invoke-virtual {v5}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v2

    .line 1180
    .local v2, path:Ljava/lang/String;
    new-instance v5, Ljava/lang/StringBuilder;

    invoke-direct {v5}, Ljava/lang/StringBuilder;-><init>()V

    const-string v6, "index="

    invoke-virtual {v5, v6}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v5

    invoke-static {p0}, Ljava/lang/String;->valueOf(I)Ljava/lang/String;

    move-result-object v6

    invoke-virtual {v5, v6}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v5

    invoke-virtual {v5}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v4

    .line 1183
    .local v4, str:Ljava/lang/String;
    :try_start_0
    new-instance v1, Ljava/io/FileOutputStream;

    invoke-direct {v1, v2}, Ljava/io/FileOutputStream;-><init>(Ljava/lang/String;)V
    :try_end_0
    .catch Ljava/io/FileNotFoundException; {:try_start_0 .. :try_end_0} :catch_1

    .line 1185
    .local v1, out:Ljava/io/FileOutputStream;
    :try_start_1
    invoke-virtual {v4}, Ljava/lang/String;->getBytes()[B

    move-result-object v5

    const/4 v6, 0x0

    invoke-virtual {v4}, Ljava/lang/String;->length()I

    move-result v7

    invoke-virtual {v1, v5, v6, v7}, Ljava/io/FileOutputStream;->write([BII)V

    .line 1186
    invoke-virtual {v1}, Ljava/io/FileOutputStream;->flush()V

    .line 1187
    invoke-virtual {v1}, Ljava/io/FileOutputStream;->getFD()Ljava/io/FileDescriptor;

    move-result-object v5

    invoke-virtual {v5}, Ljava/io/FileDescriptor;->sync()V

    .line 1188
    invoke-virtual {v1}, Ljava/io/FileOutputStream;->close()V
    :try_end_1
    .catch Ljava/io/IOException; {:try_start_1 .. :try_end_1} :catch_0
    .catch Ljava/io/FileNotFoundException; {:try_start_1 .. :try_end_1} :catch_1

    .line 1197
    .end local v1           #out:Ljava/io/FileOutputStream;
    :goto_0
    const-string v5, "FootprintUtils"

    const-string v6, "saveFootprintIndex"

    invoke-static {v5, v6}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I

    .line 1198
    return-void

    .line 1189
    .restart local v1       #out:Ljava/io/FileOutputStream;
    :catch_0
    move-exception v5

    move-object v0, v5

    .line 1190
    .local v0, e:Ljava/io/IOException;
    :try_start_2
    invoke-virtual {v0}, Ljava/io/IOException;->printStackTrace()V
    :try_end_2
    .catch Ljava/io/FileNotFoundException; {:try_start_2 .. :try_end_2} :catch_1

    goto :goto_0

    .line 1193
    .end local v0           #e:Ljava/io/IOException;
    .end local v1           #out:Ljava/io/FileOutputStream;
    :catch_1
    move-exception v5

    move-object v0, v5

    .line 1194
    .local v0, e:Ljava/io/FileNotFoundException;
    invoke-virtual {v0}, Ljava/io/FileNotFoundException;->printStackTrace()V

    goto :goto_0
.end method

.method public static setCameraBrightness(Landroid/hardware/Camera;I)V
    .locals 3
    .parameter "cameradevice"
    .parameter "brightvalue"

    .prologue
    .line 581
    if-eqz p0, :cond_0

    .line 582
    invoke-virtual {p0}, Landroid/hardware/Camera;->getParameters()Landroid/hardware/Camera$Parameters;

    move-result-object v0

    .line 583
    .local v0, p:Landroid/hardware/Camera$Parameters;
    const-string v1, "brightness"

    invoke-static {p1}, Ljava/lang/String;->valueOf(I)Ljava/lang/String;

    move-result-object v2

    invoke-virtual {v0, v1, v2}, Landroid/hardware/Camera$Parameters;->set(Ljava/lang/String;Ljava/lang/String;)V

    .line 584
    invoke-virtual {p0, v0}, Landroid/hardware/Camera;->setParameters(Landroid/hardware/Camera$Parameters;)V

    .line 586
    .end local v0           #p:Landroid/hardware/Camera$Parameters;
    :cond_0
    return-void
.end method

.method public static setCameraWhiteBalance(Landroid/hardware/Camera;Ljava/lang/String;)V
    .locals 2
    .parameter "cameradevice"
    .parameter "mode"

    .prologue
    .line 589
    if-eqz p0, :cond_0

    .line 590
    invoke-virtual {p0}, Landroid/hardware/Camera;->getParameters()Landroid/hardware/Camera$Parameters;

    move-result-object v0

    .line 591
    .local v0, p:Landroid/hardware/Camera$Parameters;
    const-string v1, "whitebalance"

    invoke-virtual {v0, v1, p1}, Landroid/hardware/Camera$Parameters;->set(Ljava/lang/String;Ljava/lang/String;)V

    .line 592
    invoke-virtual {p0, v0}, Landroid/hardware/Camera;->setParameters(Landroid/hardware/Camera$Parameters;)V

    .line 594
    .end local v0           #p:Landroid/hardware/Camera$Parameters;
    :cond_0
    return-void
.end method

.method public static setLocationToPicture(Lcom/htc/android/footprints/vo/Footprint;)V
    .locals 13
    .parameter "footprint"

    .prologue
    const-wide v11, 0x412e848000000000L

    const-string v10, "FootprintUtils"

    .line 522
    if-nez p0, :cond_0

    .line 561
    :goto_0
    return-void

    .line 524
    :cond_0
    const-string v8, "FootprintUtils"

    const-string v8, "setLocationToPicture"

    invoke-static {v10, v8}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I

    .line 530
    const/4 v5, 0x0

    .line 531
    .local v5, mExifData:Ljava/util/HashMap;,"Ljava/util/HashMap<Ljava/lang/String;Ljava/lang/String;>;"
    new-instance v0, Lcom/htc/android/footprints/utils/ExifInterface;

    iget-object v8, p0, Lcom/htc/android/footprints/vo/Footprint;->mPicPath:Ljava/lang/String;

    invoke-direct {v0, v8}, Lcom/htc/android/footprints/utils/ExifInterface;-><init>(Ljava/lang/String;)V

    .line 532
    .local v0, exif:Lcom/htc/android/footprints/utils/ExifInterface;
    if-nez v5, :cond_1

    .line 533
    invoke-virtual {v0}, Lcom/htc/android/footprints/utils/ExifInterface;->getAttributes()Ljava/util/HashMap;

    move-result-object v5

    .line 536
    :cond_1
    iget v8, p0, Lcom/htc/android/footprints/vo/Footprint;->mLatitude:I

    int-to-double v8, v8

    div-double v1, v8, v11

    .line 537
    .local v1, lat:D
    iget v8, p0, Lcom/htc/android/footprints/vo/Footprint;->mLongitude:I

    int-to-double v8, v8

    div-double v3, v8, v11

    .line 538
    .local v3, lon:D
    invoke-static {v1, v2}, Lcom/htc/android/footprints/utils/ExifInterface;->makeLatLongString(D)Ljava/lang/String;

    move-result-object v6

    .line 539
    .local v6, strLat:Ljava/lang/String;
    invoke-static {v3, v4}, Lcom/htc/android/footprints/utils/ExifInterface;->makeLatLongString(D)Ljava/lang/String;

    move-result-object v7

    .line 540
    .local v7, strLon:Ljava/lang/String;
    const-string v8, "GPSLatitude"

    invoke-static {v5, v8, v6}, Lcom/htc/android/footprints/utils/FootprintUtils;->replaceExifTag(Ljava/util/HashMap;Ljava/lang/String;Ljava/lang/String;)V

    .line 541
    const-string v8, "GPSLongitude"

    invoke-static {v5, v8, v7}, Lcom/htc/android/footprints/utils/FootprintUtils;->replaceExifTag(Ljava/util/HashMap;Ljava/lang/String;Ljava/lang/String;)V

    .line 542
    const-string v8, "GPSLatitudeRef"

    invoke-static {v1, v2}, Lcom/htc/android/footprints/utils/ExifInterface;->makeLatStringRef(D)Ljava/lang/String;

    move-result-object v9

    invoke-static {v5, v8, v9}, Lcom/htc/android/footprints/utils/FootprintUtils;->replaceExifTag(Ljava/util/HashMap;Ljava/lang/String;Ljava/lang/String;)V

    .line 543
    const-string v8, "GPSLongitudeRef"

    invoke-static {v3, v4}, Lcom/htc/android/footprints/utils/ExifInterface;->makeLatStringRef(D)Ljava/lang/String;

    move-result-object v9

    invoke-static {v5, v8, v9}, Lcom/htc/android/footprints/utils/FootprintUtils;->replaceExifTag(Ljava/util/HashMap;Ljava/lang/String;Ljava/lang/String;)V

    .line 548
    const-string v8, "FootprintUtils"

    new-instance v8, Ljava/lang/StringBuilder;

    invoke-direct {v8}, Ljava/lang/StringBuilder;-><init>()V

    const-string v9, "lat = "

    invoke-virtual {v8, v9}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v8

    invoke-virtual {v8, v6}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v8

    invoke-virtual {v8}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v8

    invoke-static {v10, v8}, Landroid/util/Log;->i(Ljava/lang/String;Ljava/lang/String;)I

    .line 549
    const-string v8, "FootprintUtils"

    new-instance v8, Ljava/lang/StringBuilder;

    invoke-direct {v8}, Ljava/lang/StringBuilder;-><init>()V

    const-string v9, "lon = "

    invoke-virtual {v8, v9}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v8

    invoke-virtual {v8, v7}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v8

    invoke-virtual {v8}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v8

    invoke-static {v10, v8}, Landroid/util/Log;->i(Ljava/lang/String;Ljava/lang/String;)I

    .line 551
    invoke-virtual {v0, v5}, Lcom/htc/android/footprints/utils/ExifInterface;->saveAttributes(Ljava/util/HashMap;)V

    .line 552
    invoke-virtual {v0}, Lcom/htc/android/footprints/utils/ExifInterface;->commitChanges()V

    goto :goto_0
.end method

.method public static setLocationToPicture(Ljava/io/File;[Ljava/lang/String;)V
    .locals 7
    .parameter "file"
    .parameter "coord"

    .prologue
    const/4 v6, 0x1

    const/4 v5, 0x0

    const-string v4, "FootprintUtils"

    .line 486
    array-length v2, p1

    if-eqz v2, :cond_0

    if-nez p0, :cond_1

    .line 519
    :cond_0
    :goto_0
    return-void

    .line 488
    :cond_1
    const-string v2, "FootprintUtils"

    const-string v2, "setLocationToPicture"

    invoke-static {v4, v2}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I

    .line 494
    const/4 v1, 0x0

    .line 495
    .local v1, mExifData:Ljava/util/HashMap;,"Ljava/util/HashMap<Ljava/lang/String;Ljava/lang/String;>;"
    new-instance v0, Lcom/htc/android/footprints/utils/ExifInterface;

    invoke-virtual {p0}, Ljava/io/File;->getAbsolutePath()Ljava/lang/String;

    move-result-object v2

    invoke-direct {v0, v2}, Lcom/htc/android/footprints/utils/ExifInterface;-><init>(Ljava/lang/String;)V

    .line 496
    .local v0, exif:Lcom/htc/android/footprints/utils/ExifInterface;
    if-nez v1, :cond_2

    .line 497
    invoke-virtual {v0}, Lcom/htc/android/footprints/utils/ExifInterface;->getAttributes()Ljava/util/HashMap;

    move-result-object v1

    .line 500
    :cond_2
    const-string v2, "GPSLatitude"

    aget-object v3, p1, v5

    invoke-static {v1, v2, v3}, Lcom/htc/android/footprints/utils/FootprintUtils;->replaceExifTag(Ljava/util/HashMap;Ljava/lang/String;Ljava/lang/String;)V

    .line 501
    const-string v2, "GPSLongitude"

    aget-object v3, p1, v6

    invoke-static {v1, v2, v3}, Lcom/htc/android/footprints/utils/FootprintUtils;->replaceExifTag(Ljava/util/HashMap;Ljava/lang/String;Ljava/lang/String;)V

    .line 507
    const-string v2, "FootprintUtils"

    new-instance v2, Ljava/lang/StringBuilder;

    invoke-direct {v2}, Ljava/lang/StringBuilder;-><init>()V

    const-string v3, "lat = "

    invoke-virtual {v2, v3}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v2

    aget-object v3, p1, v5

    invoke-virtual {v2, v3}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v2

    invoke-virtual {v2}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v2

    invoke-static {v4, v2}, Landroid/util/Log;->i(Ljava/lang/String;Ljava/lang/String;)I

    .line 508
    const-string v2, "FootprintUtils"

    new-instance v2, Ljava/lang/StringBuilder;

    invoke-direct {v2}, Ljava/lang/StringBuilder;-><init>()V

    const-string v3, "lon = "

    invoke-virtual {v2, v3}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v2

    aget-object v3, p1, v6

    invoke-virtual {v2, v3}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v2

    invoke-virtual {v2}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v2

    invoke-static {v4, v2}, Landroid/util/Log;->i(Ljava/lang/String;Ljava/lang/String;)I

    .line 510
    invoke-virtual {v0, v1}, Lcom/htc/android/footprints/utils/ExifInterface;->saveAttributes(Ljava/util/HashMap;)V

    .line 511
    invoke-virtual {v0}, Lcom/htc/android/footprints/utils/ExifInterface;->commitChanges()V

    goto :goto_0
.end method

.method public static setWidgetFlag()V
    .locals 8

    .prologue
    .line 1135
    invoke-static {}, Lcom/htc/android/footprints/utils/camera/FootprintImageManager;->getFootprintsDirectory()Ljava/lang/String;

    move-result-object v3

    .line 1137
    .local v3, sdPath:Ljava/lang/String;
    new-instance v5, Ljava/lang/StringBuilder;

    invoke-direct {v5}, Ljava/lang/StringBuilder;-><init>()V

    invoke-virtual {v5, v3}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v5

    sget-object v6, Ljava/io/File;->separator:Ljava/lang/String;

    invoke-virtual {v5, v6}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v5

    const-string v6, "fpwidget.txt"

    invoke-virtual {v5, v6}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v5

    invoke-virtual {v5}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v2

    .line 1138
    .local v2, path:Ljava/lang/String;
    const-string v4, "widget flag"

    .line 1140
    .local v4, str:Ljava/lang/String;
    :try_start_0
    new-instance v1, Ljava/io/FileOutputStream;

    invoke-direct {v1, v2}, Ljava/io/FileOutputStream;-><init>(Ljava/lang/String;)V
    :try_end_0
    .catch Ljava/io/FileNotFoundException; {:try_start_0 .. :try_end_0} :catch_1

    .line 1142
    .local v1, out:Ljava/io/FileOutputStream;
    :try_start_1
    invoke-virtual {v4}, Ljava/lang/String;->getBytes()[B

    move-result-object v5

    const/4 v6, 0x0

    invoke-virtual {v4}, Ljava/lang/String;->length()I

    move-result v7

    invoke-virtual {v1, v5, v6, v7}, Ljava/io/FileOutputStream;->write([BII)V

    .line 1143
    invoke-virtual {v1}, Ljava/io/FileOutputStream;->flush()V

    .line 1144
    invoke-virtual {v1}, Ljava/io/FileOutputStream;->getFD()Ljava/io/FileDescriptor;

    move-result-object v5

    invoke-virtual {v5}, Ljava/io/FileDescriptor;->sync()V

    .line 1145
    invoke-virtual {v1}, Ljava/io/FileOutputStream;->close()V
    :try_end_1
    .catch Ljava/io/IOException; {:try_start_1 .. :try_end_1} :catch_0
    .catch Ljava/io/FileNotFoundException; {:try_start_1 .. :try_end_1} :catch_1

    .line 1153
    .end local v1           #out:Ljava/io/FileOutputStream;
    :goto_0
    const-string v5, "FootprintUtils"

    const-string v6, "setWidgetFlag"

    invoke-static {v5, v6}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I

    .line 1154
    return-void

    .line 1146
    .restart local v1       #out:Ljava/io/FileOutputStream;
    :catch_0
    move-exception v5

    move-object v0, v5

    .line 1147
    .local v0, e:Ljava/io/IOException;
    :try_start_2
    invoke-virtual {v0}, Ljava/io/IOException;->printStackTrace()V
    :try_end_2
    .catch Ljava/io/FileNotFoundException; {:try_start_2 .. :try_end_2} :catch_1

    goto :goto_0

    .line 1150
    .end local v0           #e:Ljava/io/IOException;
    .end local v1           #out:Ljava/io/FileOutputStream;
    :catch_1
    move-exception v5

    move-object v0, v5

    .line 1151
    .local v0, e:Ljava/io/FileNotFoundException;
    invoke-virtual {v0}, Ljava/io/FileNotFoundException;->printStackTrace()V

    goto :goto_0
.end method

.method public static showFootprint(Lcom/htc/android/footprints/vo/Footprint;)V
    .locals 5
    .parameter "data"

    .prologue
    const-string v4, "--------------------------------------"

    const-string v3, "FootprintUtils"

    .line 1201
    const-string v0, "FootprintUtils"

    const-string v0, "--------------------------------------"

    invoke-static {v3, v4}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I

    .line 1202
    const-string v0, "FootprintUtils"

    new-instance v0, Ljava/lang/StringBuilder;

    invoke-direct {v0}, Ljava/lang/StringBuilder;-><init>()V

    const-string v1, "Footprint Name:"

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    iget-object v1, p0, Lcom/htc/android/footprints/vo/Footprint;->mName:Ljava/lang/String;

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v0

    invoke-static {v3, v0}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I

    .line 1203
    const-string v0, "FootprintUtils"

    new-instance v0, Ljava/lang/StringBuilder;

    invoke-direct {v0}, Ljava/lang/StringBuilder;-><init>()V

    const-string v1, "Footprint accuracy:"

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    iget v1, p0, Lcom/htc/android/footprints/vo/Footprint;->mAccuracy:I

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(I)Ljava/lang/StringBuilder;

    move-result-object v0

    invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v0

    invoke-static {v3, v0}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I

    .line 1204
    const-string v0, "FootprintUtils"

    new-instance v0, Ljava/lang/StringBuilder;

    invoke-direct {v0}, Ljava/lang/StringBuilder;-><init>()V

    const-string v1, "Footprint addr:"

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    iget-object v1, p0, Lcom/htc/android/footprints/vo/Footprint;->mAddr:Ljava/lang/String;

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v0

    invoke-static {v3, v0}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I

    .line 1205
    const-string v0, "FootprintUtils"

    new-instance v0, Ljava/lang/StringBuilder;

    invoke-direct {v0}, Ljava/lang/StringBuilder;-><init>()V

    const-string v1, "Footprint audio name:"

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    iget-object v1, p0, Lcom/htc/android/footprints/vo/Footprint;->mAudioFileName:Ljava/lang/String;

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v0

    invoke-static {v3, v0}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I

    .line 1206
    const-string v0, "FootprintUtils"

    new-instance v0, Ljava/lang/StringBuilder;

    invoke-direct {v0}, Ljava/lang/StringBuilder;-><init>()V

    const-string v1, "Footprint auido path:"

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    iget-object v1, p0, Lcom/htc/android/footprints/vo/Footprint;->mAudioPath:Ljava/lang/String;

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v0

    invoke-static {v3, v0}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I

    .line 1207
    const-string v0, "FootprintUtils"

    new-instance v0, Ljava/lang/StringBuilder;

    invoke-direct {v0}, Ljava/lang/StringBuilder;-><init>()V

    const-string v1, "Footprint category:"

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    iget-object v1, p0, Lcom/htc/android/footprints/vo/Footprint;->mCategory:Ljava/lang/String;

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v0

    invoke-static {v3, v0}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I

    .line 1208
    const-string v0, "FootprintUtils"

    new-instance v0, Ljava/lang/StringBuilder;

    invoke-direct {v0}, Ljava/lang/StringBuilder;-><init>()V

    const-string v1, "Footprint comment:"

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    iget-object v1, p0, Lcom/htc/android/footprints/vo/Footprint;->mComment:Ljava/lang/String;

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v0

    invoke-static {v3, v0}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I

    .line 1209
    const-string v0, "FootprintUtils"

    new-instance v0, Ljava/lang/StringBuilder;

    invoke-direct {v0}, Ljava/lang/StringBuilder;-><init>()V

    const-string v1, "Footprint create time:"

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    iget-wide v1, p0, Lcom/htc/android/footprints/vo/Footprint;->mCreateTime:J

    invoke-virtual {v0, v1, v2}, Ljava/lang/StringBuilder;->append(J)Ljava/lang/StringBuilder;

    move-result-object v0

    invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v0

    invoke-static {v3, v0}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I

    .line 1210
    const-string v0, "FootprintUtils"

    new-instance v0, Ljava/lang/StringBuilder;

    invoke-direct {v0}, Ljava/lang/StringBuilder;-><init>()V

    const-string v1, "Footprint drawable id:"

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    iget-wide v1, p0, Lcom/htc/android/footprints/vo/Footprint;->mDrewableID:J

    invoke-virtual {v0, v1, v2}, Ljava/lang/StringBuilder;->append(J)Ljava/lang/StringBuilder;

    move-result-object v0

    invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v0

    invoke-static {v3, v0}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I

    .line 1211
    const-string v0, "FootprintUtils"

    new-instance v0, Ljava/lang/StringBuilder;

    invoke-direct {v0}, Ljava/lang/StringBuilder;-><init>()V

    const-string v1, "Footprint latitude:"

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    iget v1, p0, Lcom/htc/android/footprints/vo/Footprint;->mLatitude:I

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(I)Ljava/lang/StringBuilder;

    move-result-object v0

    invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v0

    invoke-static {v3, v0}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I

    .line 1212
    const-string v0, "FootprintUtils"

    new-instance v0, Ljava/lang/StringBuilder;

    invoke-direct {v0}, Ljava/lang/StringBuilder;-><init>()V

    const-string v1, "Footprint longtidue:"

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    iget v1, p0, Lcom/htc/android/footprints/vo/Footprint;->mLongitude:I

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(I)Ljava/lang/StringBuilder;

    move-result-object v0

    invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v0

    invoke-static {v3, v0}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I

    .line 1213
    const-string v0, "FootprintUtils"

    new-instance v0, Ljava/lang/StringBuilder;

    invoke-direct {v0}, Ljava/lang/StringBuilder;-><init>()V

    const-string v1, "Footprint photo name:"

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    iget-object v1, p0, Lcom/htc/android/footprints/vo/Footprint;->mPicFileName:Ljava/lang/String;

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v0

    invoke-static {v3, v0}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I

    .line 1214
    const-string v0, "FootprintUtils"

    new-instance v0, Ljava/lang/StringBuilder;

    invoke-direct {v0}, Ljava/lang/StringBuilder;-><init>()V

    const-string v1, "Footprint photo path:"

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    iget-object v1, p0, Lcom/htc/android/footprints/vo/Footprint;->mPicPath:Ljava/lang/String;

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v0

    invoke-static {v3, v0}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I

    .line 1215
    const-string v0, "FootprintUtils"

    new-instance v0, Ljava/lang/StringBuilder;

    invoke-direct {v0}, Ljava/lang/StringBuilder;-><init>()V

    const-string v1, "Footprint Rate:"

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    iget v1, p0, Lcom/htc/android/footprints/vo/Footprint;->mRate:I

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(I)Ljava/lang/StringBuilder;

    move-result-object v0

    invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v0

    invoke-static {v3, v0}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I

    .line 1216
    const-string v0, "FootprintUtils"

    new-instance v0, Ljava/lang/StringBuilder;

    invoke-direct {v0}, Ljava/lang/StringBuilder;-><init>()V

    const-string v1, "Footprint Stie:"

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    iget-object v1, p0, Lcom/htc/android/footprints/vo/Footprint;->mSite:Ljava/lang/String;

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v0

    invoke-static {v3, v0}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I

    .line 1217
    const-string v0, "FootprintUtils"

    new-instance v0, Ljava/lang/StringBuilder;

    invoke-direct {v0}, Ljava/lang/StringBuilder;-><init>()V

    const-string v1, "Footprint Tel:"

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    iget-object v1, p0, Lcom/htc/android/footprints/vo/Footprint;->mTel:Ljava/lang/String;

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v0

    invoke-static {v3, v0}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I

    .line 1218
    const-string v0, "FootprintUtils"

    new-instance v0, Ljava/lang/StringBuilder;

    invoke-direct {v0}, Ljava/lang/StringBuilder;-><init>()V

    const-string v1, "Footprint Version:"

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    iget v1, p0, Lcom/htc/android/footprints/vo/Footprint;->mVersion:I

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(I)Ljava/lang/StringBuilder;

    move-result-object v0

    invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v0

    invoke-static {v3, v0}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I

    .line 1219
    const-string v0, "FootprintUtils"

    const-string v0, "--------------------------------------"

    invoke-static {v3, v4}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I

    .line 1220
    return-void
.end method

.method public static showToast(Landroid/content/Context;I)V
    .locals 1
    .parameter "context"
    .parameter "resId"

    .prologue
    .line 299
    if-eqz p1, :cond_0

    if-eqz p0, :cond_0

    .line 300
    const/4 v0, 0x1

    invoke-static {p0, p1, v0}, Landroid/widget/Toast;->makeText(Landroid/content/Context;II)Landroid/widget/Toast;

    move-result-object v0

    invoke-virtual {v0}, Landroid/widget/Toast;->show()V

    .line 302
    :cond_0
    return-void
.end method

.method public static showToast(Landroid/content/Context;Ljava/lang/String;)V
    .locals 1
    .parameter "context"
    .parameter "showmsg"

    .prologue
    .line 293
    if-eqz p1, :cond_0

    if-eqz p0, :cond_0

    .line 294
    const/4 v0, 0x1

    invoke-static {p0, p1, v0}, Landroid/widget/Toast;->makeText(Landroid/content/Context;Ljava/lang/CharSequence;I)Landroid/widget/Toast;

    move-result-object v0

    invoke-virtual {v0}, Landroid/widget/Toast;->show()V

    .line 296
    :cond_0
    return-void
.end method

.method public static touchSDFile()V
    .locals 8

    .prologue
    .line 750
    const/4 v5, 0x3

    new-array v2, v5, [Ljava/io/File;

    const/4 v5, 0x0

    new-instance v6, Ljava/io/File;

    invoke-static {}, Lcom/htc/android/footprints/utils/StorageUtil;->getFootprintStorageDirectory()Ljava/lang/String;

    move-result-object v7

    invoke-direct {v6, v7}, Ljava/io/File;-><init>(Ljava/lang/String;)V

    aput-object v6, v2, v5

    const/4 v5, 0x1

    new-instance v6, Ljava/io/File;

    invoke-static {}, Lcom/htc/android/footprints/utils/camera/FootprintImageManager;->getDirectory()Ljava/lang/String;

    move-result-object v7

    invoke-direct {v6, v7}, Ljava/io/File;-><init>(Ljava/lang/String;)V

    aput-object v6, v2, v5

    const/4 v5, 0x2

    new-instance v6, Ljava/io/File;

    invoke-static {}, Lcom/htc/android/footprints/utils/voice/FootprintVoiceManager;->getDirectory()Ljava/lang/String;

    move-result-object v7

    invoke-direct {v6, v7}, Ljava/io/File;-><init>(Ljava/lang/String;)V

    aput-object v6, v2, v5

    .line 756
    .local v2, dirs:[Ljava/io/File;
    move-object v0, v2

    .local v0, arr$:[Ljava/io/File;
    array-length v4, v0

    .local v4, len$:I
    const/4 v3, 0x0

    .local v3, i$:I
    :goto_0
    if-ge v3, v4, :cond_1

    aget-object v1, v0, v3

    .line 757
    .local v1, dir:Ljava/io/File;
    invoke-virtual {v1}, Ljava/io/File;->exists()Z

    move-result v5

    if-nez v5, :cond_0

    .line 758
    invoke-virtual {v1}, Ljava/io/File;->mkdir()Z

    .line 756
    :cond_0
    add-int/lit8 v3, v3, 0x1

    goto :goto_0

    .line 761
    .end local v1           #dir:Ljava/io/File;
    :cond_1
    return-void
.end method
